diff options
Diffstat (limited to 'numpy/core')
-rw-r--r-- | numpy/core/src/multiarray/descriptor.c | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/numpy/core/src/multiarray/descriptor.c b/numpy/core/src/multiarray/descriptor.c index 3f06acd58..b8b477e5d 100644 --- a/numpy/core/src/multiarray/descriptor.c +++ b/numpy/core/src/multiarray/descriptor.c @@ -3229,21 +3229,8 @@ arraydescr_richcompare(PyArray_Descr *self, PyObject *other, int cmp_op) PyArray_Descr *new = _convert_from_any(other, 0); if (new == NULL) { /* Cannot convert `other` to dtype */ - PyErr_Clear(); - - switch (cmp_op) { - case Py_LT: - case Py_LE: - case Py_EQ: - case Py_GT: - case Py_GE: - Py_RETURN_FALSE; - case Py_NE: - Py_RETURN_TRUE; - default: - Py_RETURN_NOTIMPLEMENTED; - } + Py_RETURN_NOTIMPLEMENTED; } npy_bool ret; |