News for hackers. Stuff that matters.
Re:Toward Go 2 by masklinn on Thursday July 13, 2017 @02:36PM (#14763919)
> The basic tradeoff is monomorphization (code duplication) vs. boxing (in Go speak, interface{}).

And even that is not the whole story, just because you reify generics does not mean you have to monomorphise everything, Microsoft's C# compiler only monomorphises value types.

Also Go may box in other contexts than interfaces depending on escape analysis (according to https://golang.org/doc/faq#stack_or_heap).

Re:Toward Go 2 by slrz on Friday July 14, 2017 @10:35AM (#14770078)
The FAQ entry does not state that the Go compiler boxes escaping variables (it doesn't, AFAICT). How did you arrive at that conclusion?