A way to check for non-simple types with `is`
zhiayang opened this issue · 0 comments
zhiayang commented
We can currently do if (x is T)
if T
is some primitive-ish type like i64
or str
or even a user-defined struct. Unfortunately we cannot match x
with something like [T]
, although I suppose that requires proper generics of some sort.