For review: PEP 308 - If-then-else expression

Erik Max Francis max at alcyone.com
Mon Feb 10 04:42:18 EST 2003


Bengt Richter wrote:

>     log.info(ok ? "failure.", "success!" )
>     print "auto colorizing turned", (self.allow_colorizing ? "off",
> "on")
> 
> is pretty clear IMO, once you get used to the order, ...

The ordering is fine, but the use of a comma to separate syntactic
structures seems like a bad idea, given its multiple uses elsewhere.  It
looks like you're maybe making a tuple.

-- 
 Erik Max Francis / max at alcyone.com / http://www.alcyone.com/max/
 __ San Jose, CA, USA / 37 20 N 121 53 W / &tSftDotIotE
/  \ Yes I'm / Learning from falling / Hard lessons
\__/ Lamya
    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