3 ms·
Go code feels very low-level to me, and very boilerplatey. In Rust I can write code that in almost the same way I write JavaScript (but with added type annotati
by nicoburns 7y ago
Go code feels very low-level to me, and very boilerplatey. In Rust I can write code that in almost the same way I write JavaScript (but with added type annotations), but Go makes me deal with all the little details, and makes it hard to abstract things neatly.
Lack of generics is a big part of the issue. But more generally the focus on "simple" code means that more sophisticated abstractions are actively eschewed, and personally I find this makes writing Go code quite frustrating.
- The_rationalist 7y agoYour comment is weird. The one making you deal with the little details should be rust, e.g go is garbage collected. Secondly, javascript + type annotations is typescript.
- Gaelan 7y agoDisclaimer: I’ve never tried to write Go. Memory management is not the only type of “little detail.” For instance, rust provides common collection operations (filer, map, find…) in the standard library. In go (AFIAK), you need to hand-write a loop for each. IMO, the rust version is takes much less mental bandwidth to write and understand.
- The_rationalist 7y agorust provides common collection operations (filer, map, find…) Those are just standard functional methods available in most languages. Go indeed is noteworthy for it's lack of features.
- Gaelan 7y agoYes, of course. I just described it as a Rust feature because that was the comparison being made in the thread.
- deleted 7y ago[deleted]