Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The way people solve that is tabs for indentation and spaces for alignment. In my opinion this is a terrible compromise as mixing tabs and spaces is sacrilegious.


There is nothing wrong with mixing tabs and spaces. It works great.


Provided everyone use the same tab width :)


Nope, works regardless of tabwidth; that's the point. Tabs for indent (these change size with tabwidth), spaces for alignment (these don't change so things stay aligned).


Oh, you're right. I should have tried it before commenting :)


Until Python. Then it doesn't.


tabs for indent, spaces for alignment works great with Python.


What's a compromise about it? Alignment and indentation are different semantic things, so it makes perfect sense to mix them.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: