Go? Coming from ruby/js background, it gets dull writing trivial day to day (repetitive) functions - before you even get to the logic.
wait for version 2
go is extremely opinionated
I'm starting to wonder if we really need generics or can we just use interfaces
Interfaces are not good enough in other scenarios.
But what are those scenarios? That's what I was asking
Wdym?
For me it is just reusability and flexibility.
A simple application is finding the sum of floats or int types
I'm thinking about DB orms, powerful tools can born in this era. Also the removal of many code generators
Generics aren’t solve that problem. Only macroses can be a replacement of the code generation.
Macros are another thing that should be added in Go. Rust macros are just so good
Typed parameters are to solve such problems, and they play a huge part in ORMs. And go generics will be about typed parameters as far as I've read
The reason was they wanted something solid before they added them to language.
I heard somewhere that the go team strongly dislikes macros because you don't normally see what code the compiler actually reads so it can leady to error messages which don't make sense to the user.
I heard they didn't like them but didn't know why
https://golang.org/doc/faq#generics
Обсуждают сегодня