Skip to content

Commit 37b2cf1

Browse files
committed
frexp is now mandatory
1 parent c304f6f commit 37b2cf1

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

numpy/core/src/npymath/npy_math_internal.h.src

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ NPY_INPLACE double npy_log2(double x)
9898
{
9999
#ifdef HAVE_LOG2
100100
return log2(x);
101-
#elif defined(HAVE_FREXP)
101+
#else
102102
if (!npy_isfinite(x) || x <= 0.) {
103103
/* special value result */
104104
return npy_log(x);
@@ -123,9 +123,6 @@ NPY_INPLACE double npy_log2(double x)
123123
return log(m) / log(2.0) + e;
124124
}
125125
}
126-
#else
127-
/* does not provide int(log(2**i)) == i */
128-
return NPY_LOG2E * npy_log(x);
129126
#endif
130127
}
131128

0 commit comments

Comments
 (0)