PEP-308 a "simplicity-first" alternative

Michele Simionato mis6 at pitt.edu
Wed Feb 12 10:47:14 EST 2003


Christian Tismer <tismer at tismer.com> wrote in message news:<mailman.1045008759.8715.python-list at python.org>...
> ruud de rooij wrote:
> > holger krekel <pyth at devel.trillke.net> writes:
> > 
> > 
> >>        x and y else z
> > 
> > 
> > as long as people are proposing alternatives, what about:
> > 
> >   c then x else y
> 
> Please note my copyright on this! :-)
> > 
> > if this has already been proposed and discarded, my apologies.
> 
> Proposed but not discarded, yet.
> I'm in favor of any of the two,
> anyway. Better than all I saw so far.
> 
> (pythonic and small) then vote() else forget() -- chris

I also thought of this yesterday night and discovered that it was already 
proposed by Nick Vargish and others. Nick seems to prefer the "and" trick, but
I am still in favor of "then" (See R. Hettinger and A. Koenig comments in this
thread). It can be done a pseudo-keyword. Anyway, my scan of the 2.2 standard
library (60,000+ lines of code) shows that "then" is *never* used as
as a keyword.

+1 to "then"


                          Michele




More information about the Python-list mailing list