[docs] [issue12211] Better document math.copysign behavior.
report at bugs.python.org
Sun Feb 16 17:19:04 CET 2014
Mark Dickinson added the comment:
The paragraph about NaNs isn't correct. For example:
>>> from math import copysign
>>> copysign(1.0, float('nan'))
>>> copysign(1.0, -float('nan'))
Though it doesn't really make sense to talk about 'positive' or 'negative' NaNs, a NaN still has a sign bit, and that sign bit is used in the copysign operation.
Python tracker <report at bugs.python.org>
More information about the docs