diff options
author | Christian Heimes <christian@cheimes.de> | 2008-01-25 14:54:23 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2008-01-25 14:54:23 (GMT) |
commit | 543cabc84290972872f596c5c5a6660ad8aade15 (patch) | |
tree | 679fa0561fdb56d897c928e8516d0f7787078072 /Modules/mathmodule.c | |
parent | 7f39c9fcbba0cc59293d80a7bbcbb8bca62790ee (diff) | |
download | cpython-543cabc84290972872f596c5c5a6660ad8aade15.zip cpython-543cabc84290972872f596c5c5a6660ad8aade15.tar.gz cpython-543cabc84290972872f596c5c5a6660ad8aade15.tar.bz2 |
setup.py doesn't pick up changes to a header file
Diffstat (limited to 'Modules/mathmodule.c')
-rw-r--r-- | Modules/mathmodule.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/mathmodule.c b/Modules/mathmodule.c index 0440871..6469bde 100644 --- a/Modules/mathmodule.c +++ b/Modules/mathmodule.c @@ -240,11 +240,11 @@ loghelper(PyObject* arg, double (*func)(double), char *funcname) "math domain error"); return NULL; } - /* Value is ~= x * 2**(e*SHIFT), so the log ~= - log(x) + log(2) * e * SHIFT. - CAUTION: e*SHIFT may overflow using int arithmetic, + /* Value is ~= x * 2**(e*PyLong_SHIFT), so the log ~= + log(x) + log(2) * e * PyLong_SHIFT. + CAUTION: e*PyLong_SHIFT may overflow using int arithmetic, so force use of double. */ - x = func(x) + (e * (double)SHIFT) * func(2.0); + x = func(x) + (e * (double)PyLong_SHIFT) * func(2.0); return PyFloat_FromDouble(x); } |