
On 03.11.2016 02:06, MRAB wrote:
On 2016-11-02 21:57, Greg Ewing wrote:
MRAB wrote:
target = expr1 || expr2 || expr3 target = expr1 && expr2 && expr3
except that only None would be considered falsey?
Or would that be confusing?
Yes, I think that borrowing an operator from C but giving it subtly different semantics would be *very* confusing, especially to people more familiar with C than Python. They're going to look at it and *think* they know what it means, except they don't.
OK, if we're going to have ?. and ?[, then:
target = expr1 ?| expr2 ?| expr3 target = expr1 ?& expr2 ?& expr3
A disadvantage is that they look a little like | and &, which don't short-circuit.
Many recent proposals were out-right rejected by a majority of Python users and developers because of it's cryptic, Perl-like appearance. Don't you think ?., ?[..], ??, ?|, ?& etc. don't look Perlish and cryptic? Best, Sven