site banner

Friday Fun Thread for November 22, 2024

Be advised: this thread is not for serious in-depth discussion of weighty topics (we have a link for that), this thread is not for anything Culture War related. This thread is for Fun. You got jokes? Share 'em. You got silly questions? Ask 'em.

2
Jump in the discussion.

No email address required.

Because there's usually a rule about maximum line length, in order to keep lines fitting inside the screen or window. Variable-length tabs play havoc with that rule, and auto-formatters would be constantly flipping lines back and forth as code was touched by different developers. Which introduces a lot of extra noise into commits.

Not to mention that sometimes we use tabs to deliberately format things into columns, not just indent code. Variable-length tabs throw that off.

All in all, the gains from having the code look the exact same for each developer outweighs the individual aesthetic gain of your preferred tab size.

,>Because there's usually a rule about maximum line length, in order to keep lines fitting inside the screen or window.

There's really no need for this anymore, it would be trivial to have the editor wrap the line in a nice way (go has no line length limits in the official style guide).

Not to mention that sometimes we use tabs to deliberately format things into columns, not just indent code. Variable-length tabs throw that off.

That's just an abuse of notation. Spaces are for alignment.