Author mark.dickinson
Recipients adamtj, bas, bertchughes, facundobatista, jdunck, lorg, mark.dickinson, rhettinger, skrah
Date 2010-03-14.11:52:31
SpamBayes Score 0.000311906
Marked as misclassified No
Message-id <>
Here's a patch:

  - comparisons between a Decimal and float produce a result based
    on the numeric values of the Decimal and float

  - change Decimal.__hash__ so that floats and Decimals with (exactly)
    equal value have the same hash.  This preserves the rule that if
    two objects compare equal then they hash equal.

  - add tests, and update documentation.

Still open:  should this change be forward ported to py3k?  If not, then these comparisons should produce a DeprecationWarning.
Date User Action Args
2010-03-14 11:52:36mark.dickinsonsetrecipients: + mark.dickinson, rhettinger, facundobatista, jdunck, lorg, skrah, adamtj, bertchughes, bas
2010-03-14 11:52:35mark.dickinsonsetmessageid: <>
2010-03-14 11:52:33mark.dickinsonlinkissue2531 messages
2010-03-14 11:52:33mark.dickinsoncreate