For God so loved his children that we finally have a programming language that has solved the
This is truly exciting news! In recent years, I’d resigned my position to “use spaces everywhere” because of two justifications:
Spacesare near-impossible to mess up (across all editors and programmers)
Tabsare technically control characters and “do not belong in files” (eg: you wouldn’t put
^Gin your file, so why put
golang bucks tradition in a particularly compelling way:
Tabs are indeed
control characters (increasing indent for control-flow modification), and due to near-ubiquitous use of
gofmt, it’s also near-impossible to mess up(!).
If you control exactly the language, the compiler, and the formatter, it’s an incredibly compelling simplification to use
tabs. Most editors “support them as expected” such that backspace and tab are commutative. This is effectively an upgrade for a moderate amount of people who were stuck backspacing over spaces.
Any misbehaving editor or stubborn user who uses spaces instead will simply get processed through the mold of
gofmt … their transgressions are short-lived and forgivable.
Small victories may lead to large victories… with the
spaces debate definitively settled, mayhaps we finally can move on to figuring out Elastic Tabstops.