News for hackers. Stuff that matters.
Re:Golang generics proposal has been accepted by Arnavion on Wednesday February 10, 2021 @03:20PM (#26094170)
A more apt comparison is TypeScript to JavaScript, perhaps. Kotlin and Java interop at the bytecode level, but Golang doesn't have that. Gotlin would have to compile to Golang with the same shimming hairiness as TS downleveling to JS.
Re:Golang generics proposal has been accepted by cies on Wednesday February 10, 2021 @03:26PM (#26094267)
Well spotted. Though typescript does not fix some of the biggest horrors of JS. Interop is really good as one would expect.
Re:Golang generics proposal has been accepted by mssundaram on Wednesday February 10, 2021 @03:47PM (#26094549)
I'd say it depends on how you tune your tsconfig and linting. You can really crank all the knobs avoid nearly all of the JS pitfalls
Re:Golang generics proposal has been accepted by cies on Wednesday February 10, 2021 @04:11PM (#26094868)
Agreed. But this is not very beginner friendly (sadly JS is more and more the first lang being taught), and is not an example of great design.
Re:Golang generics proposal has been accepted by AlphaSite on Wednesday February 10, 2021 @04:00PM (#26094730)
Considering that go is only really used in a statically compiled context, thats not really necessary.