FWIW, Qualified +1 on PEP-0308

Craeg K Strong cstrong at arielpartners.com
Fri Feb 28 17:05:17 EST 2003


Hello:

I would like to register another +1 vote for an if-then-else expression 
in Python,
specifically for Christian Tismer's proposed variant:

       <condition> then <expression1> else <expression2>

   The advantages are simple visual parsing, no required parenthesis,
   no change in the semantics of existing keywords, not as likely
   as the proposal to be confused with statement syntax, and does
   not further overload the colon.  The disadvantage is the
   implementation costs of introducing a new keyword.  However,
   unlike other new keywords, the word "then" seems unlikely to
   have been used as a name in existing programs.

The argument against it, the cost of implementation, is mostly 
irrelevant. It is incurred only once, and by the suppliers, not by the 
consumers.
All the other advantages of the syntax trump the other proposals.

Many thanks,

--Craeg Strong

-- 
Craeg K Strong, General Partner
Ariel Partners LLC
http://www.arielpartners.com
voice 781-647-2425
fax   781-647-9690







More information about the Python-list mailing list