Hacker News new | past | comments | ask | show | jobs | submit login

Why? n spaces encode a specific preference for indentation, while tabs just represent a level of indentation. How many columns these actually are is entirely up to personal preference and editor configuration. That's why tabs are always superior for indentation.



It's actually quite a bit more subtle than that. Even `go fmt` uses tabs to format indentation, but uses spaces to format alignment. This is distinct from mechanical typewriters which used variably sized tab-stops to handle tab alignment.




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

Search: