Author mark.dickinson
Recipients belopolsky, drj, ggenellina, haypo, mark.dickinson
Date 2008-12-09.21:02:36
SpamBayes Score 9.58748e-05
Marked as misclassified No
Message-id <1228856557.61.0.544208850404.issue3166@psf.upfronthosting.co.za>
In-reply-to
Content
> floating-point variable "x" has an exact nonnegative integer value 
> between 0 and 2**DBL_MANT_DIG. 

Hmm.  On closer inspection that's not quite true.  After the line

x = x * PyLong_BASE + (dig & (PyLong_BASE - pmask));

x has a value of the form n * pmask, where pmask is a power of 2 and
n is in the range [0, 2**DBL_MANT_DIG).  It's still exactly represented, 
provided that FLT_RADIX is 2.  (It's the multiplications by powers of 2 
that get hairy when FLT_RADIX is 16, since they *can* lose information.)
History
Date User Action Args
2008-12-09 21:02:37mark.dickinsonsetrecipients: + mark.dickinson, belopolsky, ggenellina, haypo, drj
2008-12-09 21:02:37mark.dickinsonsetmessageid: <1228856557.61.0.544208850404.issue3166@psf.upfronthosting.co.za>
2008-12-09 21:02:36mark.dickinsonlinkissue3166 messages
2008-12-09 21:02:36mark.dickinsoncreate