Attack a sacred Python Cow

cokofreedom at cokofreedom at
Thu Jul 24 17:00:19 CEST 2008

> Please understand that I'm not arguing about this particular design
> choice (and FWIW, I'd mostly agree on the point that having a != b
> different from not (a == b) is actually a wart). I'm just correcting
> your statement about the behaviour of __eq__ / __ne__ not being
> documented, which is obviously false.
> (snip)

What was the reasoning behind having both __eq__ / __ne__ anyway? To
fit in with the equality comparisons?  I do agree this one seems like
a wart, but not a serious one. I'd say it would make more sense for
the interpreter to provide a warning on classes that define one and
not that other, at least if set to a certain level, similar to -3 for

(Or does this exist? I think a "wart" catching level that outputs
potential warts and issues would be a useful addition!)

More information about the Python-list mailing list