MCPcopy Create free account
hub / github.com/numpy/numpy / arraymapiter_dealloc

Function arraymapiter_dealloc

numpy/core/src/multiarray/mapping.c:3432–3451  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3430
3431
3432static void
3433arraymapiter_dealloc(PyArrayMapIterObject *mit)
3434{
3435 PyArray_ResolveWritebackIfCopy(mit->array);
3436 Py_XDECREF(mit->array);
3437 Py_XDECREF(mit->ait);
3438 Py_XDECREF(mit->subspace);
3439 Py_XDECREF(mit->extra_op);
3440 Py_XDECREF(mit->extra_op_dtype);
3441 if (mit->outer != NULL) {
3442 NpyIter_Deallocate(mit->outer);
3443 }
3444 if (mit->subspace_iter != NULL) {
3445 NpyIter_Deallocate(mit->subspace_iter);
3446 }
3447 if (mit->extra_op_iter != NULL) {
3448 NpyIter_Deallocate(mit->extra_op_iter);
3449 }
3450 PyArray_free(mit);
3451}
3452
3453/*
3454 * The mapiter object must be created new each time. It does not work

Callers

nothing calls this directly

Calls 2

NpyIter_DeallocateFunction · 0.85

Tested by

no test coverage detected