Linked by Thom Holwerda on Mon 25th Jun 2007 20:10 UTC, submitted by ganges master
General Development Guido van Rossum, the creator of the Python programming language, has published on his blog an interesting status report for Python 3.0 ('Python 3000'), the upcoming major revision to the language scheduled for mid-2008. He discusses the rationale for redesigning the language, syntax changes, new features and libraries and inter-compatibility issues.
Thread beginning with comment 250595
To read all comments associated with this story, please click here.
Re: Indentation
by richmoore on Tue 26th Jun 2007 08:56 UTC
richmoore
Member since:
2005-08-06

Do you think it's a practical problem or is it just that you don't like it?

Whilst I like python and use it a lot both at home and at work, I have definitely had problems resulting from this. The trouble is that as soon as the indentation is damaged, either by someone using an editor that is configured to use hard tabs or by copying code to another place (eg. to move it into a function) then the semantics of the code are destroyed. I can live with this, but I think the people who are claim 'there is no problem' are just burying their heads in the sand.

Reply Score: 3

RE: Re: Indentation
by dagw on Tue 26th Jun 2007 09:15 in reply to "Re: Indentation"
dagw Member since:
2005-07-06

While I have broken code in the ways you describe, it is never really hard to fix. On the other hand doing this forces you to re-format your code consistently and thus improving readability.

I find it very annoying to read C or Java code where the indenting and bracketing changes halfway through because they copied in code from somewhere else or something like that.

Reply Parent Score: 5

RE[2]: Re: Indentation
by Spellcheck on Tue 26th Jun 2007 21:19 in reply to "RE: Re: Indentation"
Spellcheck Member since:
2007-01-20

On the other hand doing this forces you to re-format your code consistently and thus improving readability.

I am a lazy programmer. I don't want to be forced to do anything!

Reply Parent Score: 1

RE: Re: Indentation
by japh on Tue 26th Jun 2007 09:24 in reply to "Re: Indentation"
japh Member since:
2005-11-11

The trouble is that as soon as the indentation is damaged, either by someone using an editor that is configured to use hard tabs or by copying code to another place (eg. to move it into a function)

Yes, those might be problems. An editor that isn't python-aware, can mess things up for you, so that is something to watch out for. I haven't really seen those problems myself, but it might be a bigger issue than I realize.

Copy-paste bugs, I have had. Unittesting catches almost all of those for me. Even if there was no risk of error in copy-paste, I'd still not feel comfortable about code that didn't go through unittesting, so for me that's not additional work.

Yes, there are situations where those are real problems. But there are also ways to avoid most of those situations.

Reply Parent Score: 1

RE[2]: Re: Indentation
by Core Duo on Tue 26th Jun 2007 12:11 in reply to "RE: Re: Indentation"
Core Duo Member since:
2007-06-24

I've coded in Python since 2002. I love it. It's fast.

Reply Parent Score: 4

RE: Re: Indentation
by Magma on Tue 26th Jun 2007 16:26 in reply to "Re: Indentation"
Magma Member since:
2006-03-07

I completely agree.

Having been bitten by this bug in python a number of times I just gave up on it. I was just wasting time fixing tabs and burning up all the benefit that a scripting language is supposed to give.

I won't use it until they add "end" constructs or { } semantics.

Reply Parent Score: 1