|
|
|
|
|
by yuribro
1945 days ago
|
|
I don't understand the jump from the lack of algebraic types, to using interface{}. You can spell out all your types into explicit structs (where you can choose between a simple implementation with a little worse performance or to make the implementation a little more complex) and pass them around. There are many complex code bases (kernels & databases come to mind) which use C (not C++), and they don't resort to passing void* around the "business logic" parts. The idea that for a complex project you would choose a different language with so many different characteristics due to a minor detail about the type system (this is not exactly Haskell vs JS...). This kind of decision making would not pass in any reasonable organization... |
|
No, it's more like Haskell vs C, considering the expressiveness of Rust’s vs Go’s type system.