I feel so stupid writing this in #Rust

```
if let SomeCons(_) = x { true } else { false }
```

anyone knows of some better solution?

I just need to do that in one place, so I don't think that hiding this dirty code under a method just for that one call is a good solution.

@typeable

x.is_some() // ?

Maybe, I'm missing some context.

@vrotgaru Thanks! But this only works if it's an Option, but I have my own enum for a DSL