class Foo[of T(IComparable[of T])]:
pass
Foo[of int]() // error occurs here
Expected: This should work, as Int32 implements IComparable<Int32>.
Observed: The generic type checker errors out here, as it incorrectly checks whether int implements the generic IComparable[of T], rather than the reified IComparable[of int].
Expected: This should work, as
Int32
implementsIComparable<Int32>
. Observed: The generic type checker errors out here, as it incorrectly checks whetherint
implements the genericIComparable[of T]
, rather than the reifiedIComparable[of int]
.