TABS in the CPython C source code

Steve Holden steve at holdenweb.com
Sun Feb 7 07:46:52 EST 2010


Dennis Lee Bieber wrote:
> On Sun, 07 Feb 2010 05:49:28 +0000, Nobody <nobody at nowhere.com>
> declaimed the following in gmane.comp.python.general:
> 
> 
>> 8-column tabs aren't a "*nix convention"; that's been the norm since
>> the mechanical typewriter.
>>
> 	Really? None of the various Royal, Remington, and Olivetti (sp?)
> typewriters I learned on had any knowledge of default tab stops. All had
> a row of sliding "pins" on the carriage, which were slid back and forth
> by the <tab set> and <tab clear> button (which required one to first
> position the carriage at the position at which the stop was to be
> placed). The <tab> key itself functioned by first pushing a lever into
> the area covered by the stop-row (after the current position stop, if
> one existed), then releasing the carriage to slide until the next stop
> -- uhm -- stopped the motion by impacting the lever; releasing the <tab>
> key would then re-engage the normal carriage motion control, and
> withdraw the lever.
> 
> 	8-space tab stops were, I believe, the default for various computer
> terminals, DECwriter printers, and maybe teletype units (in which there
> was no moving carriage on which a physical stop could be placed). Not
> sure how an 029 keypunch machine would behave -- either punching the
> code the a tab character, or skipping to the next field defined on a
> drum-card.
> 
When I started my computing career the main input medium at the
installation I worked was paper tape, and the Flexowriter (pretty much a
mechanical typewriter mechanism with a tape reader and punch attached)
was the data preparation device (though teletypes were used at other
installations). So it had adjustable tab settings.

The 029 punch (and the 026 before it) used a punch card mounte on a drum
to set the tab stops, which were therefore completely variable - one
would use a different tab card for Fortran and PL/1, for example. So a
tab was purely a spacing operation, no chads were punched from the card,
and indeed I was never aware of an EBCDIC "tab" character code (which is
by no means to say that there isn't one - Wikipedia says "The EBCDIC
code for HT is 5").

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