Mark Dickinson added the comment:

More examples, showing that `y` is not ignored when `x` is a NaN.

>>> result1 = copysign(float('nan'), 1.0)
>>> result2 = copysign(float('nan'), -1.0)
>>> copysign(1.0, result1)  # result1 is a NaN whose sign bit is cleared.
1.0
>>> copysign(1.0, result2)  # result2 is a NaN whose sign bit is set.
-1.0

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue12211>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to