Does Python need an 'xor' operator?

Tim Peters tim.one at comcast.net
Sun Apr 14 17:24:52 EDT 2002


I doubt that a new "xor" operator will ever get in (compelling use cases are
conspicuous by absence), but anyone pushing for it had better push for a new
"eqv" operator too (that is, if you're going to claim that it's ugly that
x^y may not return one of its argument, surely it's just as ugly that the
same holds for x==y).






More information about the Python-list mailing list