Skip to content

Commit e1e22ae

Browse files
committed
NAN is not always defined in math.h, so using Py_NAN
1 parent 0cf411d commit e1e22ae

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

pandas/_libs/src/klib/khash_python.h

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
#include <string.h>
2-
#include <math.h>
32
#include <Python.h>
43

54
#include "khash.h"
@@ -31,7 +30,7 @@ khint64_t PANDAS_INLINE asint64(double key) {
3130

3231
// correct for all
3332
#define kh_float64_hash_func(key) ((key) != (key) ? \
34-
kh_float64_hash_func_NAN(NAN) : \
33+
kh_float64_hash_func_NAN(Py_NAN) : \
3534
kh_float64_hash_func_NAN(key))
3635

3736
#define kh_float64_hash_equal(a, b) ((a) == (b) || ((b) != (b) && (a) != (a)))

0 commit comments

Comments
 (0)