Next floating point number

Tim Peters tim.peters at gmail.com
Sun Dec 18 11:25:44 EST 2005


[Bengt Richter]
> I wonder if frexp is always available,

Yes, `frexp` is a standard C89 libm function.  Python's `math` doesn't
contain any platform-specific functions.

...

> The math module could also expose an efficient multiply by a power
> of two using FSCALE if the pentium FPU is there.

`ldexp` is also a standard C89 libm function, so Python also exposes
that.  Whether it uses FSCALE is up to the platform C libm.



More information about the Python-list mailing list