3 ms·
I’m ignorant to golang’s generics saga, but I’m painfully familiar with Java’s (to the point where I wasn’t overly sad when golang didn’t have them). Can anyone
by tarkin2 6y ago
I’m ignorant to golang’s generics saga, but I’m painfully familiar with Java’s (to the point where I wasn’t overly sad when golang didn’t have them). Can anyone explain what golang is doing better?
- hu3 6y agoThey're different languages with different goals. Such comparison wouldn't be constructive nor conclusive.
- cle 6y agoGo is designing generics around the language tenets, which are quite different from Java's. In themselves, generics aren't particularly interesting...it gets interesting when you start considering the tradeoffs you need to make in order to align them with the tenets of your language, runtime, and ecosystem. I wouldn't say Go is doing generics "better", they are doing them "differently" to align with the goals of the language. (Personally, I'm not looking forward to generics in Go, I enjoy the simplicity of not having them and haven't encountered situations where they'd make a huge difference.)