summaryrefslogtreecommitdiff
path: root/numpy/core/src
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/core/src')
-rw-r--r--numpy/core/src/ufuncobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/core/src/ufuncobject.c b/numpy/core/src/ufuncobject.c
index 4f5b29825..8a4f828d8 100644
--- a/numpy/core/src/ufuncobject.c
+++ b/numpy/core/src/ufuncobject.c
@@ -3440,7 +3440,7 @@ typedef struct {
static int
cmp_arg_types(int *arg1, int *arg2, int n)
{
- while (n--) {
+ for (;n>0; n--, arg1++, arg2++) {
if (PyArray_EquivTypenums(*arg1, *arg2)) continue;
if (PyArray_CanCastSafely(*arg1, *arg2))
return -1;