Prothon Prototypes vs Python Classes

John Roth newsgroups at jhrothjr.com
Mon Mar 29 03:26:46 CEST 2004


"Michael" <mogmios at mlug.missouri.edu> wrote in message
news:mailman.21.1080516361.20120.python-list at python.org...
> They're planning to remove tab indention support in 3.0? I for one would
> be pissed off at such a change. I don't mind people using spaces if they
> like but I see no reason I shouldn't be able to use tabs if I like. I
> can't see how it should make any difference to Python which you use so
> why not allow for personal preference?

The basic difficulty with tabs is that there are a huge
number of programs "in the wild" that treat tabs
differently. Unless you're completely in control of all
the programs that will ever be used to edit and display
your program, using tabs will cause formatting errors
somewhere, to someone under some circumstance
that you never thought of.

The problems with mixed tabs and spaces are even
worse: you can lose indentation and totally mess up
the program so it won't even compile if you use the
wrong tools on such a program.

This is the basic reason why the current standard for
library modules is 4 space indentation; it's the only
thing that is, for all practical purposes, guaranteed to
work for everyone, with any editor, formatter,
renderer and printer out there.

Python is not Perl. Python's philosophy has never
been to provide several different ways of doing things
just to provide different ways. There needs to be a
demonstrated benefit to the different ways, and tabs
don't make that cut. If you want the space savings,
ziping the file will do much better.

John Roth






More information about the Python-list mailing list