logoalt Hacker News

9rxlast Tuesday at 7:03 PM3 repliesview on HN

> lets not forget that the Go team made the same blunder made by Java

To be fair, they were working on parametric polymorphism since the beginning. There are countless public proposals, and many more that never made it beyond the walls of Google.

Problem was that they struggled to find a design that didn't make the same blunder as Java. I'm sure it would have been easy to add Java-style generics early on, but... yikes. Even the Java team themselves warned the Go team to not make that mistake.


Replies

karmakazelast Tuesday at 7:19 PM

At least Java supports covariance and contravariance where Go only supports invariant generics.

show 1 reply
throwaway2037last Wednesday at 3:22 AM

    > blunder made by Java
For normies, what is wrong with Java generics? (Do the same complaints apply to C# generics?) I came from C++ to Java, and I found Java generics pretty easy to use. I'm not interested in what "PL (programming language) people" have to say about it. They dislike all generic/parametric polymorphism implementations except their pet language that no one uses. I'm interested in practical things that work and are easy for normies to learn and use well.

    > Even the Java team themselves warned the Go team to not make that mistake.
Do you have a source for that?
show 3 replies
pjmlpyesterday at 5:31 PM

Should I repost the blog posts where they acknowledge the failure to look into languages like CLU?