TABS in the CPython C source code

Steve Holden steve at holdenweb.com
Sun Feb 7 07:39:24 EST 2010


Nobody wrote:
> On Sat, 06 Feb 2010 21:31:52 +0100, Alf P. Steinbach wrote:
> 
>> The size-8 tabs look really bad in an editor configured with tab size 4,
>> as is common in Windows. I'm concluding that the CPython programmers
>> configure their Visual Studio's to *nix convention.
> 
> 8-column tabs aren't a "*nix convention"; that's been the norm since
> the mechanical typewriter.
> 
Clearly written by someone who has never *used* a mechanical typewriter.
The original mechanisms had "tab set" and "tab clear" keys, so you had
variable tabbing according to the needs of the particular document you
were working on. Look under "T" in

  http://www.mytypewriter.com/explorelearn/glossary.html

if you aren't old enough to have used one.

> Historically, software and hardware which knows what a "tab" could be
> split into two categories:
> 
> 1. Tab stops are fixed at 8-column intervals.
> 2. Tab stops default to 8-column intervals but can be changed.
> 
> Recently, a third category has appeared (tab stops default to something
> other than 8 columns). The most common example is Visual Studio. No
> surprise there: Microsoft has a track record of introducing slight
> incompatibilities into established standards. Just enough to inconvenience
> anyone using competing products, but not so much that anyone operating
> in a context where Microsoft isn't dominant has to abandon Microsoft's
> product.
> 
Consider instead that perhaps this one time Microsoft did it for the
convenience of the user (there has to be some reason why it's such a
wealthy company).

> Given that:
> 
> 1. 8-column tabs have been the standard for longer than most of us
> have been alive, let alone programming, and
> 2. even if a particular text editor supports some other value, there is no
> way to communicate this fact to anything else which might read the code,
> 
> the logical conclusion is that using anything other than 8 columns lies
> somewhere between "silly" and "assuming the world revolves around you".
> 

Which is what you appear to be doing with your fantasy about mechanical
typewriters.

regards
 Steve
-- 
Steve Holden           +1 571 484 6266   +1 800 494 3119
PyCon is coming! Atlanta, Feb 2010  http://us.pycon.org/
Holden Web LLC                 http://www.holdenweb.com/
UPCOMING EVENTS:        http://holdenweb.eventbrite.com/




More information about the Python-list mailing list