[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Tabs v.s. spaces (was Re: Programming first steps.)



On Mon, Nov 17, 2003 at 06:02:40PM -0800, Tom wrote:
> If whitespace mistakes are always caught at compile-time, then I
> probably wouldn't care about them either.  So I'm not bashing python;
> having never used it: I'm bashing languages where syntatic mistakes
> are not caught at compile-time.  I have no idea if Python is in that
> category or not.

Python does catch inconsistent indenting at compile time.  If you want
to catch mixed tabs/spaces for block indenting, run python with -tt.  As
Stephen clarified earlier, Python uses significant indentation, not
significant whitespace.  Variables and objects are not defined by
whitespace, the nested scope of logical blocks are.

-- 
Chad Walstrom <chewie@wookimus.net>           http://www.wookimus.net/
           assert(expired(knowledge)); /* core dump */

Attachment: pgpyHzFENE4Ke.pgp
Description: PGP signature


Reply to: