Skip to content

Commit 62b628c

Browse files
committed
Add NPY_ARRAY_DEFAULT flag
1 parent 302a297 commit 62b628c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

numpy/_core/src/multiarray/item_selection.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -245,10 +245,10 @@ PyArray_TakeFrom(PyArrayObject *self0, PyObject *indices0, int axis,
245245
}
246246

247247
indices = (PyArrayObject *)PyArray_FromAny(indices0,
248-
PyArray_DescrFromType(NPY_INTP),
249-
0, 0,
250-
NPY_ARRAY_SAME_KIND_CASTING,
251-
NULL);
248+
PyArray_DescrFromType(NPY_INTP),
249+
0, 0,
250+
NPY_ARRAY_SAME_KIND_CASTING | NPY_ARRAY_DEFAULT,
251+
NULL);
252252
if (indices == NULL) {
253253
goto fail;
254254
}

0 commit comments

Comments
 (0)