PEP-308 a "simplicity-first" alternative

Jp Calderone exarkun at intarweb.us
Fri Feb 14 22:04:44 EST 2003


On Fri, Feb 14, 2003 at 06:36:02PM -0800, Erik Max Francis wrote:
> Terry Reedy wrote:
> 
> > "Erik Max Francis" <max at alcyone.com> wrote in message
> > news:3E4C8329.1C13F41A at alcyone.com...
> >
> > > There is nothing wrong with Python's `and' and `or' semantics; they're
> > > very similar in functionality to those used in Lisp, for instance.
> > > However, the use of the _idiom_ combining the two in order to attempt
> > > to the effect of a conditional operator -- `C and x or y' -- is
> > > idiomatic, unreadable, and _wrong_.
> > 
> > What do you mean when you say it is 'wrong' to combine two selection
> > operators to make a selection expression?
> 
> I'm saying it's wrong because the `C and x or y' form as a substitute for
> a conditional operator does not work as expected in the case of x being
> false, as has been mentioned time and time again.

  Which is to say, it does not do what *some* people think it does.

  I guess we should get rid of most language constructs, if this is the
criterion by which they are to be judged.

  still-minus-one'ly,

  Jp

-- 
There are 10 kinds of people: those who understand binary and those who do
not.
-- 
 up 6 days, 8:27, 4 users, load average: 0.20, 0.05, 0.01
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/python-list/attachments/20030214/7951835e/attachment.sig>


More information about the Python-list mailing list