URL: http://github.com/python/cpython/commit/58ceecfe5ac0ad436d556b589870dd2df62731c0
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7ed4294 commit 58ceecfCopy full SHA for 58ceecf
2 files changed
Misc/NEWS
@@ -49,6 +49,9 @@ Core and Builtins
49
Library
50
-------
51
52
+- Issue #18513: Fix behaviour of cmath.rect w.r.t. signed zeros on OS X 10.8 +
53
+ gcc.
54
+
55
- Issue #18480: Add missing call to PyType_Ready to the _elementtree extension.
56
57
- Issue #17778: Fix test discovery for test_multiprocessing. (Patch by
Modules/cmathmodule.c
@@ -1006,6 +1006,13 @@ cmath_rect(PyObject *self, PyObject *args)
1006
else
1007
errno = 0;
1008
}
1009
+ else if (phi == 0.0) {
1010
+ /* Workaround for buggy results with phi=-0.0 on OS X 10.8. See
1011
+ bugs.python.org/issue18513. */
1012
+ z.real = r;
1013
+ z.imag = r * phi;
1014
+ errno = 0;
1015
+ }
1016
else {
1017
z.real = r * cos(phi);
1018
z.imag = r * sin(phi);
0 commit comments