How We Got the Generics We Have (Or, how I learned to stop worrying and love erasure) by @BrianGoetz openjdk.java.net/projects/valha… After 18+ months, I finally got around to read this one and it's really informative. Here are the closing arguments to what pushed Java to erasure. 🧵
Migration compatibility There was no known translation scheme at the time that would have allowed a migration to reified generics to be source- and binary-compatible, thus creating flag days and invalidating developer’s considerable investment in their existing code.
@nipafx @BrianGoetz Great read! One detail isn't 100% correct though. There are programs that break that guarantee. (They are quite contrived though, and I think it's ok to ignore them in a text about erasure.) raw.githubusercontent.com/namin/unsound/…
@nipafx @BrianGoetz I look forward to Valhalla.👍 If it doesn't only deliver value types but "improved generics" where you can create your own primitive types, then this will be a quantum leap in Java. I am not sure whether other programming languages like Kotlin go so far ...