[Python-Dev] Withdrawn PEP 288 and thoughts on PEP 342

Raymond Hettinger python at rcn.com
Fri Jun 17 06:43:32 CEST 2005


[Phillip]
> > I also personally don't care about the new continue feature, 
> > so I could do without for-loop alteration too.  

[Guido]
> I do like "continue EXPR" but I have to admit I haven't even tried to
> come up with examples -- it may be unnecessary. As Phillip says, yield
> expressions and g.next(EXPR) are the core -- and also incidentally
> look like they will cause the most implementation nightmares. 

Let me go on record as a strong -1 for "continue EXPR".  The for-loop is
our most basic construct and is easily understood in its present form.
The same can be said for "continue" and "break" which have the added
advantage of a near zero learning curve for people migrating from other
languages.

Any urge to complicate these basic statements should be seriously
scrutinized and held to high standards of clarity, explainability,
obviousness, usefulness, and necessity.  IMO, it fails most of those
tests. 

I would not look forward to explaining "continue EXPR" in the tutorial
and think it would stand out as an anti-feature.



Raymond


More information about the Python-Dev mailing list