Let's make Python really strict about indentation
alexis.layton at post.harvard.edu
Mon Dec 3 19:18:40 CET 2001
Alexis Layton wrote:
> I'm starting to believe the only solution to the indentation "mixups"
> that occur
> is to have Python become really strict about indentation, yet still
> allow a mixture
> of spaces and tabs.
My previous post still does not address one common use-case (the Unix
where tab-stops are 8 and indentation level is 4, where the following
This pattern, as well as all common ones, can be addressed by defining
(for the purposes of lexical analysis of Python) that the tab stop is
large integer, say 256. Or one can use the algorithm described in my
but allow a single T to be more indentation than any number of Ss.
This would allow any internally consistent file to be parsed but
mixtures of identation.
More information about the Python-list