|
I've only done a bit of Go. I liked some of the ideas that were present, but ultimately (and I believe explicitly) Go has computer-sciencey-correctness goals (hence all the kerfluffle over generics) that, now and again, trip things up. Sometimes that's really nice - we had a handful of tiny utilities written in Go, like a format converter for use in a datastream - other times it gets in the way. I don't think I'd want to code up something large in Go, although it's not something I've had the opportunity to try. AFAICT, Go believes in preventing you from making certain mistakes. And usually, within it's context and paradigm, it's correct to do so. The problems arise when your problem domain doesn't line up well with that context and/or paradigm, which sometimes just comes down to the time you can spend on the issue. Another example: IMHO, all the weird issues Go was having working out how to do package management stems from some (admittedly very cool) ideas about Correct And Proper Package Management. I can't remember the last time I had an issue with gem management / bundler (except for the perennially awkward PG gem issue). It's a 85% vs 95% thing, and IMO that straight-up comes from having other priorities. There's a lot of overlap between "developer happiness" and "computational correctness", but it's not exact, and that comes up in few, but enough, places. Maybe another good example is Ruby array arithmetic. It makes no bloody sense from a math/CS perspective, but goddamn it is handy in applications. So if your language is aiming for computational correctness, you're not going to get that tiny bit of joy. |
I really don't understand this. The debate over generics had nothing to do with "computer sciencey correctness" goals, they had to do with ergonomics. Of course, from Ruby, the idea of typing your code is completely foreign, but imagine if a function only allowed one type of parameter, and if you wanted another you had to define it again with a different name.
Basically like allowing flexible parameters makes function definitions more flexible, a lot like all the metaprogramming business in Ruby