mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
Fix HAVE_DECL_ISINF/ISNAN test (again).
This commit is contained in:
parent
41fbae1ac9
commit
0ebfedf38e
1 changed files with 2 additions and 2 deletions
|
@ -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 && HAVE_DECL_ISNAN == 1
|
||||
#if defined 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 && HAVE_DECL_ISINF == 1
|
||||
#if defined 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))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue