flax icon indicating copy to clipboard operation
flax copied to clipboard

A way to check for non-simple types with `is`

Open zhiayang opened this issue 6 years ago • 0 comments

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.

zhiayang avatar Oct 20 '19 10:10 zhiayang