A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2009-January/085286.html below:

Add a "while" clause to generator expressions

[Python-Dev] PEP 3142: Add a "while" clause to generator expressions [Python-Dev] PEP 3142: Add a "while" clause to generator expressionsTres Seaver tseaver at palladion.com
Wed Jan 21 20:02:55 CET 2009
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Vitor Bosshard wrote:

>> Some also allow for an "until" keyword.  I'm not suggesting that we
>> need to do this in Python; it's just interesting to note that there is
>> some precedent for this approach.
>>
> 
> Well, you could propose changing the for loop syntax (and by
> extension comprehensions and generators). It's a much more radical proposal, but
> it does keep consistency across the board, which is one of the major
> flaws of the PEP in its current form.
> 
> BTW, there is already an "until" keyword in python, it's called "while not" ;)

'until' is used at least in some languages (Pascal, Modula*, maybe Ada?)
for a "terminate at bottom" loop (one guaranteed to run at least once):
 in such cases, the predicate has the negative sense.


Tres.
- --
===================================================================
Tres Seaver          +1 540-429-0999          tseaver at palladion.com
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJd3Ff+gerLs4ltQ4RAuOQAJ47EA8Cf1KPMdNiZTBiJqweiUNZBgCgsVrc
38fgphB+hjdnTblAQT8Q5tA=
=SeEn
-----END PGP SIGNATURE-----

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4