[Python-Dev] Decimal <-> float comparisons in py3k.

Greg Ewing greg.ewing at canterbury.ac.nz
Thu Mar 18 00:49:24 CET 2010


Steven D'Aprano wrote:

> More explicit than someDecimal == someFloat? Seems pretty explicit to 
> me.

Yes. I mean at least specifying either float(someDecimal) == someFloat 
or someDecimal == Decimal(someFloat). Preferably also whether the
conversion is to be as exact as possible or on a minimum-digits basis.

-- 
Greg


More information about the Python-Dev mailing list