[issue2531] float compared to decimal is silently incorrect.

Raymond Hettinger report at bugs.python.org
Sat Mar 21 18:38:09 CET 2009


Raymond Hettinger <rhettinger at users.sourceforge.net> added the comment:

I think "the best we can do" is return valid comparison results between
floats and decimals in 2.x.  It doesn't make anything worse and it does
make something better.  Unlike other cross-type comparisons,
number-to-number is not an unreasonable thing to do.  And, we not
obliged to carry that over to 3.x where cross-type comparisons have to
be specifically enabled.  I believe this is the best solution.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue2531>
_______________________________________


More information about the Python-bugs-list mailing list