| 2329 | } |
| 2330 | |
| 2331 | static PyObject * |
| 2332 | npyiter_close(NewNpyArrayIterObject *self, PyObject *NPY_UNUSED(args)) |
| 2333 | { |
| 2334 | NpyIter *iter = self->iter; |
| 2335 | int ret; |
| 2336 | if (self->iter == NULL) { |
| 2337 | Py_RETURN_NONE; |
| 2338 | } |
| 2339 | ret = NpyIter_Deallocate(iter); |
| 2340 | self->iter = NULL; |
| 2341 | Py_XDECREF(self->nested_child); |
| 2342 | self->nested_child = NULL; |
| 2343 | if (ret != NPY_SUCCEED) { |
| 2344 | return NULL; |
| 2345 | } |
| 2346 | Py_RETURN_NONE; |
| 2347 | } |
| 2348 | |
| 2349 | static PyObject * |
| 2350 | npyiter_exit(NewNpyArrayIterObject *self, PyObject *NPY_UNUSED(args)) |
no test coverage detected