News for hackers. Stuff that matters.
Re:Go 1.11 and Beyond by coldtea on Saturday August 25, 2018 @09:23PM (#17843662)
>It's pretty difficult for generics not to adversely affect compile times.

Compared to what? Non having type-specific code?

Because if you manually write (or use code generation madness as some propose) that type specific code you need yourself, then the compiler will take the same time to compile it as if generics were a language feature.

Re:Go 1.11 and Beyond by foldr on Sunday August 26, 2018 @06:49AM (#17845290)
The compiler also has to generate the specialized code. But I suspect that the main factor here is just that the presence of generics in a language encourages the use of generic programming to an extent that wouldn't be practical in a language without generics. Take e.g. the boost geometry library (C++). Theoretically you could write a similarly generic library in Go using code generation, and it would probably take ages to build too. Of course, no-one would actually do this.