diff options
author | Sergey B Kirpichev <skirpichev@gmail.com> | 2023-02-09 08:40:52 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-09 08:40:52 (GMT) |
commit | 58395759b04273edccf3d199606088e0703ae6b1 (patch) | |
tree | 16d612f7e3e357a9741f42d10d6cceb7f3d0f897 /Modules/_math.h | |
parent | 244d4cd9d22d73fb3c0938937c4f435bd68f32d4 (diff) | |
download | cpython-58395759b04273edccf3d199606088e0703ae6b1.zip cpython-58395759b04273edccf3d199606088e0703ae6b1.tar.gz cpython-58395759b04273edccf3d199606088e0703ae6b1.tar.bz2 |
gh-101678: refactor the math module to use special functions from c11 (GH-101679)
Shouldn't affect users, hence no news.
Automerge-Triggered-By: GH:mdickinson
Diffstat (limited to 'Modules/_math.h')
-rw-r--r-- | Modules/_math.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Modules/_math.h b/Modules/_math.h index 4a6bc22..2285b64 100644 --- a/Modules/_math.h +++ b/Modules/_math.h @@ -7,8 +7,9 @@ static double _Py_log1p(double x) { - /* Some platforms supply a log1p function but don't respect the sign of - zero: log1p(-0.0) gives 0.0 instead of the correct result of -0.0. + /* Some platforms (e.g. MacOS X 10.8, see gh-59682) supply a log1p function + but don't respect the sign of zero: log1p(-0.0) gives 0.0 instead of + the correct result of -0.0. To save fiddling with configure tests and platform checks, we handle the special case of zero input directly on all platforms. |