summaryrefslogtreecommitdiffstats
path: root/Include
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2009-01-04 16:41:08 (GMT)
committerMark Dickinson <dickinsm@gmail.com>2009-01-04 16:41:08 (GMT)
commit7894a7255f1e6e0468e9e673c119be09bebf5e35 (patch)
tree894824d5d52f52c470eb518bf5a6118cd5719eeb /Include
parent3809026a72472593a43038315eb597bedb6403e7 (diff)
downloadcpython-7894a7255f1e6e0468e9e673c119be09bebf5e35.zip
cpython-7894a7255f1e6e0468e9e673c119be09bebf5e35.tar.gz
cpython-7894a7255f1e6e0468e9e673c119be09bebf5e35.tar.bz2
Merged revisions 68302 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r68302 | mark.dickinson | 2009-01-04 16:06:40 +0000 (Sun, 04 Jan 2009) | 4 lines Oops. Need to check not only that HAVE_DECL_ISINF is defined, but also that it's equal to 1. (If isinf isn't defined, HAVE_DECL_ISINF is defined to be 0, rather than being undefined.) ........
Diffstat (limited to 'Include')
-rw-r--r--Include/pymath.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/Include/pymath.h b/Include/pymath.h
index 13f95b4..9e0f46f 100644
--- a/Include/pymath.h
+++ b/Include/pymath.h
@@ -87,7 +87,7 @@ extern double copysign(double, double);
* Note: PC/pyconfig.h defines Py_IS_NAN as _isnan
*/
#ifndef Py_IS_NAN
-#ifdef HAVE_DECL_ISNAN
+#ifdef HAVE_DECL_ISNAN && HAVE_DECL_ISNAN == 1
#define Py_IS_NAN(X) isnan(X)
#else
#define Py_IS_NAN(X) ((X) != (X))
@@ -104,7 +104,7 @@ extern double copysign(double, double);
* Note: PC/pyconfig.h defines Py_IS_INFINITY as _isinf
*/
#ifndef Py_IS_INFINITY
-#ifdef HAVE_DECL_ISINF
+#ifdef HAVE_DECL_ISINF && HAVE_DECL_ISINF == 1
#define Py_IS_INFINITY(X) isinf(X)
#else
#define Py_IS_INFINITY(X) ((X) && (X)*0.5 == (X))