Message from discussion Why not enforce four space indentations in version 3.x?
Date: Tue, 14 Jul 2009 11:06:17 -0700
From: John Nagle <na...@animats.com>
User-Agent: Thunderbird 18.104.22.168 (Windows/20070728)
Subject: Re: Why not enforce four space indentations in version 3.x?
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
NNTP-Posting-Date: 14 Jul 2009 18:04:49 GMT
> I believe Guido himself has said that all indentions should be four
> spaces - no tabs.
> Since backward compatibility is being thrown away anyway, why not
> enforce the four space rule?
> At least that way, when I get python code from somebody else, I would
> know what I am looking at, without having to do a hex dump, or
Python 3 enforces the rule that you can't mix tabs and spaces
for indentation in the same file. That (finally) guarantees that
the indentation you see is what the Python parser sees. That's
enough to prevent non-visible indentation errors.
It also means that the Python parser no longer has to have
any concept of how many spaces equal a tab. So the problem
is now essentially solved.