Incorrect Decimal-Float behaviour in comparison tests
Fredrik Lundh
fredrik at pythonware.com
Fri Mar 3 13:23:40 EST 2006
Tim Hochberg wrote:
> It's not a bug, but it is a misfeature. In 3.0, I'd love to see
> nonsensical comparisons raise TypeError, but still keep the ability to
> sort lists of heterogeneous objects. One approach would be keep cmp(x,y)
> permissive in its arguments while making __gt__ and friends strict.
"Comparisons other than == and != between disparate types will
raise an exception unless explicitly supported by the type"
http://www.python.org/peps/pep-3000.html
</F>
More information about the Python-list
mailing list