3 ms·
Real generics are almost as addictive as C# templates - i.e. after going back to Java, you feel the pain _every single day_.
by sz4kerto 13y ago
Real generics are almost as addictive as C# templates - i.e. after going back to Java, you feel the pain _every single day_.
- jbrechtel 13y agoIn what way, specifically, do you feel this pain?
- alkonaut 13y agoReflection showing erased types. Slow collections because internal arrays are object[]. Various caveats with bridge methods/ClassCastExceptions. The list goes on and on. Erasure isn't a pragmatic design decision, it's an utterly and fundamentally broken design. Reified generics are both simpler to implement AND more performant AND more powerful in terms of metaprogramming. I fail to see the argument for erasure apart from backwards compatibility (which isn't really an argument).
- deleted 13y ago[deleted]
- bad_user 13y agoI liked C#, but everything changed after I picked up Scala.