by js2 · 10y ago · 0 comments
But what happens in practice is that the file ends up with a mish-mash of tabs and spaces throughout and the file is only legible if you set your tab stop to a specific setting, and sometimes not even then because different authors have used different tab stops for both indentation and alignment. At which point the tabs buy you nothing.
So just use spaces and be done with it. Or go fmt. :-)
Here's some Befunge interpreters in a few different languages: https://github.com/serprex/Befunge
There is no other way to do tabs. Anything else is simply wrong and grounds for execu... a stern talking-to.
Simply use indentation in the places where you might be tempted to start lining up columns.
It's really easy to use an alignment-free style. A good way to get in the habit is to code in a proportional font instead of monospaced. By doing that, you won't be able to use column alignment, and you'll naturally gravitate toward using indentation to represent the block structure of your code.
As someone who tabs, 4 is a very common standard, and consistency has never been a problem.