diff options
author | David Cournapeau <cournape@gmail.com> | 2009-03-10 13:47:28 +0000 |
---|---|---|
committer | David Cournapeau <cournape@gmail.com> | 2009-03-10 13:47:28 +0000 |
commit | 6433987c284e239395d3582ea70d682310c9db0d (patch) | |
tree | 1f7c10c6ee991989cc9ce063144666beaefd8c8c /numpy/core/src/numpyos.c | |
parent | 325893788a6acdc49158b12635fc9788b0fd56e2 (diff) | |
download | numpy-6433987c284e239395d3582ea70d682310c9db0d.tar.gz |
Remove NumpyOS_init, obsoleted by our NPY_NAN and co macros.
Diffstat (limited to 'numpy/core/src/numpyos.c')
-rw-r--r-- | numpy/core/src/numpyos.c | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/numpy/core/src/numpyos.c b/numpy/core/src/numpyos.c index f5337a861..319b4806d 100644 --- a/numpy/core/src/numpyos.c +++ b/numpy/core/src/numpyos.c @@ -321,48 +321,6 @@ _ASCII_FORMAT(long double, l, long double) _ASCII_FORMAT(long double, l, double) #endif -#if 0 -static double NPY_INFINITY; /* Positive infinity */ -static double NPY_PZERO; /* +0 */ -static double NPY_NAN; /* NaN */ - -/* NumPyOS_init: - * - * initialize floating-point constants - */ -static void -NumPyOS_init(void) { - double mul = 1e100; - double div = 1e10; - double tmp, c; - - tmp = 0; - c = mul; - for (;;) { - c *= mul; - if (c == tmp) { - break; - } - tmp = c; - } - NPY_INFINITY = c; - - tmp = 0; - c = div; - for (;;) { - c /= div; - if (c == tmp) { - break; - } - tmp = c; - } - - NPY_PZERO = c; - NPY_NAN = NPY_INFINITY / NPY_INFINITY; -} -#endif - - /* * NumPyOS_ascii_isspace: * |