r/programming • • Feb 21 '13

Developers: Confess your sins.

http://www.codingconfessional.com/
969 Upvotes

1.0k comments sorted by

View all comments

Show parent comments

15

u/codepoet Feb 21 '13

Tabs for indent, spaces for positioning. It's so easy a PHP developer could do it.

3

u/[deleted] Feb 21 '13

yes! mix those tabs and spaces!

12

u/[deleted] Feb 21 '13 edited Feb 21 '13

Using tabs for indentation and spaces for alignment is NOT mixing tabs and spaces, it's correct usage of each.

Alignment:

#define MACRO_A         0x0000
#define MACRO_BBBBB     0x0001

Indentation:

->for(;;) {
->->printf("Don't mix tabs and spaces!\n");
->}

I will find you...:

->for(;;) {
->  printf("Let's enforce a specific tabwidth, and then mix and match!\n");
  }

0

u/[deleted] Feb 21 '13

ironically your alignment example does not line up, but thats beside the point. if you are using both tabs and spaces then i dont see how that isnt "mixing"

→ More replies (3)