PEP 308: "then" "else" for deprecating "and" "or" side effects
Erik Max Francis
max at alcyone.com
Fri Feb 14 19:28:12 EST 2003
François Pinard wrote:
> If I translate the keywords of our syntax back to English, it gives:
>
> a when b else c
This doesn't look like a good counter to the `C then x else y' proposal,
since using `when' as the keyboard would imply the same ordering as the
original proposal:
x when C else y
as in, "Put a jacket on when it's old cold outside, otherwise [else]
where what you want." This form (with the condition in the middle) has
already been suggested -- in fact, it was one of the first alternatives
to the first if/else proposal brought up.
Using it to mean
C when x else y
definitely "reads" wrong in English; if you want this form, the `when'
should be a `then'.
--
Erik Max Francis / max at alcyone.com / http://www.alcyone.com/max/
__ San Jose, CA, USA / 37 20 N 121 53 W / &tSftDotIotE
/ \ You win the victory when you yield to friends.
\__/ Sophocles
Bosskey.net: Quake III Arena / http://www.bosskey.net/q3a/
A personal guide to Quake III Arena.
More information about the Python-list
mailing list