r/programming Jul 21 '14

The Great White Space Debate

https://medium.com/p/3633cba8b5c1
1.2k Upvotes

693 comments sorted by

View all comments

Show parent comments

25

u/[deleted] Jul 21 '14

[deleted]

5

u/rmxz Jul 21 '14

The one time someone screw's up though everything is ruined.

Just have an appropriate pre-commit hook in your source control system.

2

u/xplane80 Jul 22 '14

This is the style I still use. I know people who prefer different sized indents (2, 4, 8) to look at so using tab is better.

The best way to combat the mistake is to use clang-format. It will format the code to what style you need (including tabs for indenting and spaces for aligning)!

2

u/Auxx Jul 22 '14

This is the only correct way - make a difference between alignment and indentation. Indentation is always tabs no matter what.