by codeflo · 4y ago · 0 comments
That’s a basic fact of type safety that people often get wrong. For example, the JVM famously allows upcasting arrays, with very surprising results.
But even an immutable list cannot be made covariant. Or, say, funcs.