3 ms·
The second example is avoidable by forbidding mixed use of tabs and spaces, as in the two directly following each other. The first example doesn't do what you w
by est31 5y ago
The second example is avoidable by forbidding mixed use of tabs and spaces, as in the two directly following each other. The first example doesn't do what you want really as x and y are part of the commented out code.
- kazinator 5y agoThe second example requires a careful mix of leading indentation tabs followed by alignment spaces in order to work correctly: so the editing user can vary the tab size locally, while seeing the correct alignment. If you forbid the mixed leading tabs and spaces, while insisting on tabs for indentation, then you're ruling out code formatting styles which exhibit such alignment. That's a worse position that banishing tabs, because you are dictating code formatting ideologies for the sake of your indentation method. The situation of tabs being banished does not, by itself, dictate to what the code should look like.