News for hackers. Stuff that matters.
Re:Type erasure and reification by int_19h on Wednesday December 05, 2018 @04:53PM (#18613000)
> MS actually doesn’t use generics as aggressively as it could in its API for similar reasons (eg there are two APIs for collections that use genetics and don’t).

All modern .NET APIs use generics heavily, and have done so since at least C# 3.5 (e.g. LINQ is pretty much all generics).

The reason why there are two collection APIs is because one of them predates generics. It is generally considered deprecated and rarely used, with exception of untyped IEnumerable, and that mostly because it's the base interface of IEnumerable<T>. It's not dissimilar to how Java also has legacy collections from 1.0 days.

Re:Type erasure and reification by CuriousSkeptic on Thursday December 06, 2018 @08:52AM (#18618011)
The non-generic super-interface pattern isn’t completely deprecated. It’s still advocated as a workaround for the lack of existential types in the language.