[issue26785] repr of -nan value should contain the sign

Hrvoje Abraham report at bugs.python.org
Sat Apr 16 15:45:06 EDT 2016


Hrvoje Abraham added the comment:

Reported issue was created in 64-bit Python 3.5.1 (v3.5.1:37a07cee5969, Dec  6 2015, 01:54:25) [MSC v.1900 64 bit (AMD64)] on win32.

Now I noticed that in Py 2.7 even copysign part does not work as expected.

Python 2.7.11 (v2.7.11:6d1b6a68f775, Dec  5 2015, 20:40:30) [MSC v.1500 64 bit (AMD64)] on win32:

>>> from math import copysign
>>> x = float("-nan")
>>> copysign(1.0, x)
1.0

Not correct.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26785>
_______________________________________


More information about the Python-bugs-list mailing list