summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2008-10-05 05:19:52 +0000
committerCharles Harris <charlesr.harris@gmail.com>2008-10-05 05:19:52 +0000
commit10ed170a5d4e82024c2b4deff7d4c3549e3e4ff4 (patch)
treeced8bf91cb317c052805b77721bf082a1d520439
parent176328e827919d0a7c84fe6b026f4422bd605874 (diff)
downloadnumpy-10ed170a5d4e82024c2b4deff7d4c3549e3e4ff4.tar.gz
Fix invalid use of identity fmax,fmin.
-rw-r--r--numpy/core/code_generators/generate_umath.py9
-rw-r--r--numpy/core/include/numpy/ufuncobject.h1
2 files changed, 4 insertions, 6 deletions
diff --git a/numpy/core/code_generators/generate_umath.py b/numpy/core/code_generators/generate_umath.py
index 533c3a037..a7ebd93fb 100644
--- a/numpy/core/code_generators/generate_umath.py
+++ b/numpy/core/code_generators/generate_umath.py
@@ -6,7 +6,6 @@ sys.path.pop(0)
Zero = "PyUFunc_Zero"
One = "PyUFunc_One"
-Nan = "PyUFunc_Nan"
None_ = "PyUFunc_None"
class TypeDescription(object):
@@ -318,14 +317,14 @@ defdict = {
TD(O, f='_npy_ObjectMin')
),
'fmax' :
- Ufunc(2, 1, Nan,
+ Ufunc(2, 1, None,
"",
- TD(inexact),
+ TD(inexact)
),
'fmin' :
- Ufunc(2, 1, Nan,
+ Ufunc(2, 1, None,
"",
- TD(inexact),
+ TD(inexact)
),
'bitwise_and' :
Ufunc(2, 1, One,
diff --git a/numpy/core/include/numpy/ufuncobject.h b/numpy/core/include/numpy/ufuncobject.h
index 7935b60e2..91f37f99c 100644
--- a/numpy/core/include/numpy/ufuncobject.h
+++ b/numpy/core/include/numpy/ufuncobject.h
@@ -184,7 +184,6 @@ typedef struct {
#define PyUFunc_One 1
#define PyUFunc_Zero 0
#define PyUFunc_None -1
-#define PyUFunc_Nan NAN
#define UFUNC_REDUCE 0
#define UFUNC_ACCUMULATE 1