3 ms·
The lack of debate over line-to-line code style (because it is enforced by a standard formatter) is one of the reasons I still enjoy using Go, and that's despit
by georgemcbay 3y ago
The lack of debate over line-to-line code style (because it is enforced by a standard formatter) is one of the reasons I still enjoy using Go, and that's despite the fact that it doesn't use what was my preferred C-era brace style.
Just absolutely eliminating it as something to worry or argue about is something a lot more languages could benefit from, IMO.
And yes, while other languages have third-party formatting and linting tools that can enforce an agreed-upon standard, in the real world that just never works out as well (once a codebase grows beyond a couple of contributors) as having it be truly standardized in the language itself.
- kzrdude 3y agoI think go has the benefit of the syntax being simple enough that not as much debate is needed. That is a legitimate feature of the language, and why not enjoy it. This comes already from the design of the language, I would say. I'm comparing to Rust, and I'm not surprised that there are more different ways to format Rust and not always a way to make everyone happy.
- jeremyjh 3y ago> in the real world that just never works out as well (once a codebase grows beyond a couple of contributors) Can you elaborate on this? Once you have a linter/formatter in your CI loop, how does it stop working just because you have more contributors? My main project at work uses Elixir - which has a built in formatter - and Javascript - which doesn't. We use eslint for Javascript and haven't touched its config in years as devs come and go.