| 1894 | } |
| 1895 | |
| 1896 | static PyObject * |
| 1897 | array_reduce_ex_regular(PyArrayObject *self, int NPY_UNUSED(protocol)) |
| 1898 | { |
| 1899 | PyObject *subclass_array_reduce = NULL; |
| 1900 | PyObject *ret; |
| 1901 | |
| 1902 | /* We do not call array_reduce directly but instead lookup and call |
| 1903 | * the __reduce__ method to make sure that it's possible to customize |
| 1904 | * pickling in sub-classes. */ |
| 1905 | subclass_array_reduce = PyObject_GetAttrString((PyObject *)self, |
| 1906 | "__reduce__"); |
| 1907 | if (subclass_array_reduce == NULL) { |
| 1908 | return NULL; |
| 1909 | } |
| 1910 | ret = PyObject_CallObject(subclass_array_reduce, NULL); |
| 1911 | Py_DECREF(subclass_array_reduce); |
| 1912 | return ret; |
| 1913 | } |
| 1914 | |
| 1915 | static PyObject * |
| 1916 | array_reduce_ex_picklebuffer(PyArrayObject *self, int protocol) |
no outgoing calls
no test coverage detected