3 ms·
That’s more a side effect of the tooling than the language itself tho. “ Gofmt's style is no one's favorite, yet gofmt is everyone's favorite.” https://go-pro
by taywrobel 6y ago
That’s more a side effect of the tooling than the language itself tho.
“ Gofmt's style is no one's favorite, yet gofmt is everyone's favorite.”
https://go-proverbs.github.io/ https://go-proverbs.github.io/
- eat_veggies 6y agonot sure I agree. the ability to comprehend code goes way beyond surface-level formatting, especially since gofmt doesn't actually do that much
- kortex 6y agoI concur. It's not just gofmt (although it is great). With go and an IDE, I can drill straight down and basically hit "bottom of the stack" within <5-7 jumps of "jump to definition" (C-b for me). Python it's like layer on layer on layer of indirection, "clever" code everywhere, and frequently the track runs cold. I don't have to sit there and study some inscrutable nugget for minutes/hours cause it's all obvious. Not sure if it's the language, culture, or both, but I love it.
- cle 6y agoThe language goes out of its way to minimize concepts, the number of ways state can be mutated (eg no thread locals), over-abstraction, and dynamic meta-programming. It emphasizes explicit control flow, preferring code duplication that is easy to read, over minimizing duplication by creating complex abstractions or implicit runtime behavior. There are a lot of cases where these tradeoffs suck and add a bunch of unnecessary friction. And there are many cases where it boosts overall productivity significantly.
- Cthulhu_ 6y agoIt's not just the formatting though, I think it's the lack of magic and options; when you compare it with Java, every library will have its own style and approach to doing things. in Go, things are a lot more consistent - either because of the language, or because of conventions. I've always considered Scala to be the linear opposite of Go, where over time they have bolted more and more (advanced) features and syntax until you end up with libraries and code as extreme as scalaz [1], and of course every developer will have their own Opinion on how things should be written, formatted, etc. Scala adds choice, Go reduces it. Oftentimes the argument is "but you don't have to use all these features! you can write Scala just like Java", but in practice that's not how it works. I mean just a for loop is already a headscratcher in Scala. [1]https://github.com/scalaz/scalaz https://github.com/scalaz/scalaz