News for hackers. Stuff that matters.
Re:Golang: How to Update APIs for Generics by ddevault on Thursday September 16, 2021 @04:50AM (#28549473)
It's not a breaking change, but it is a radical change for what it means for Go programs to be Go programs. All Go programs are now written the "wrong" way. Or, in other words: all present Go programs would not pass a code review if they were introduced following the release of Go 2. This also affects many libraries throughout the ecosystem, increasing the API churn and burden on downstream projects. It will create millions of man-hours of work for Go users.
Re:Golang: How to Update APIs for Generics by dpatterbee on Thursday September 16, 2021 @06:23AM (#28549947)
Every Go program written using interface{} to provide psuedo-generics was known to be "wrong" at the time it was written, unfortunately the "right" way wasn't a part of the language so people put up with it. I don't believe that generics are going to radically shift any facet of Go programming and I predict that a year from now they'll be just another feature of the language.

If somebody's refactoring some area of code that heavily uses interface{} or code generation maybe they'll considered rewriting parts, but interface{} and code generation are not deprecated or made obsolete by generics.

Re:Golang: How to Update APIs for Generics by pjmlp on Thursday September 16, 2021 @05:48AM (#28549751)
They will still compile with a Go 2.0 compiler, try to run a Python 2.7 script on Python 3.9.