Issue #2531: Make float-to-decimal comparisons return correct results.

Float to decimal comparison operations now return a result based on
the numeric values of the operands.  Decimal.__hash__ has also been
fixed so that Decimal and float values that compare equal have equal
hash value.
This commit is contained in:
Mark Dickinson 2010-04-02 08:53:22 +00:00
parent 6eba779235
commit 99d8096c17
4 changed files with 74 additions and 13 deletions

View file

@ -35,6 +35,11 @@ Core and Builtins
Library
-------
- Issue #2531: Comparison operations between floats and Decimal
instances now return a result based on the numeric values of the
operands; previously they returned an arbitrary result based on
the relative ordering of id(float) and id(Decimal).
- Issue #8233: When run as a script, py_compile.py optionally takes a single
argument `-` which tells it to read files to compile from stdin. Each line
is read on demand and the named file is compiled immediately. (Original