blob: d0b70c46ff5707ba731e388e68d7f260f62b44d7 [file] [log] [blame]
Brett Cannon1eb32c22014-10-10 16:26:45 -04001/*[clinic input]
2preserve
3[clinic start generated code]*/
4
5PyDoc_STRVAR(array_array___copy____doc__,
6"__copy__($self, /)\n"
7"--\n"
8"\n"
9"Return a copy of the array.");
10
11#define ARRAY_ARRAY___COPY___METHODDEF \
12 {"__copy__", (PyCFunction)array_array___copy__, METH_NOARGS, array_array___copy____doc__},
13
14static PyObject *
15array_array___copy___impl(arrayobject *self);
16
17static PyObject *
18array_array___copy__(arrayobject *self, PyObject *Py_UNUSED(ignored))
19{
20 return array_array___copy___impl(self);
21}
22
23PyDoc_STRVAR(array_array___deepcopy____doc__,
24"__deepcopy__($self, unused, /)\n"
25"--\n"
26"\n"
27"Return a copy of the array.");
28
29#define ARRAY_ARRAY___DEEPCOPY___METHODDEF \
30 {"__deepcopy__", (PyCFunction)array_array___deepcopy__, METH_O, array_array___deepcopy____doc__},
31
32PyDoc_STRVAR(array_array_count__doc__,
33"count($self, v, /)\n"
34"--\n"
35"\n"
36"Return number of occurrences of v in the array.");
37
38#define ARRAY_ARRAY_COUNT_METHODDEF \
39 {"count", (PyCFunction)array_array_count, METH_O, array_array_count__doc__},
40
41PyDoc_STRVAR(array_array_index__doc__,
42"index($self, v, /)\n"
43"--\n"
44"\n"
45"Return index of first occurrence of v in the array.");
46
47#define ARRAY_ARRAY_INDEX_METHODDEF \
48 {"index", (PyCFunction)array_array_index, METH_O, array_array_index__doc__},
49
50PyDoc_STRVAR(array_array_remove__doc__,
51"remove($self, v, /)\n"
52"--\n"
53"\n"
54"Remove the first occurrence of v in the array.");
55
56#define ARRAY_ARRAY_REMOVE_METHODDEF \
57 {"remove", (PyCFunction)array_array_remove, METH_O, array_array_remove__doc__},
58
59PyDoc_STRVAR(array_array_pop__doc__,
60"pop($self, i=-1, /)\n"
61"--\n"
62"\n"
63"Return the i-th element and delete it from the array.\n"
64"\n"
65"i defaults to -1.");
66
67#define ARRAY_ARRAY_POP_METHODDEF \
Serhiy Storchaka4a934d42018-11-27 11:27:36 +020068 {"pop", (PyCFunction)(void(*)(void))array_array_pop, METH_FASTCALL, array_array_pop__doc__},
Brett Cannon1eb32c22014-10-10 16:26:45 -040069
70static PyObject *
71array_array_pop_impl(arrayobject *self, Py_ssize_t i);
72
73static PyObject *
Serhiy Storchakaa5552f02017-12-15 13:11:11 +020074array_array_pop(arrayobject *self, PyObject *const *args, Py_ssize_t nargs)
Brett Cannon1eb32c22014-10-10 16:26:45 -040075{
76 PyObject *return_value = NULL;
77 Py_ssize_t i = -1;
78
Serhiy Storchaka4fa95912019-01-11 16:01:14 +020079 if (!_PyArg_CheckPositional("pop", nargs, 0, 1)) {
Victor Stinner259f0e42017-01-17 01:35:17 +010080 goto exit;
81 }
Serhiy Storchaka4fa95912019-01-11 16:01:14 +020082 if (nargs < 1) {
83 goto skip_optional;
84 }
Serhiy Storchaka4fa95912019-01-11 16:01:14 +020085 {
86 Py_ssize_t ival = -1;
Serhiy Storchaka5f4b229d2020-05-28 10:33:45 +030087 PyObject *iobj = _PyNumber_Index(args[0]);
Serhiy Storchaka4fa95912019-01-11 16:01:14 +020088 if (iobj != NULL) {
89 ival = PyLong_AsSsize_t(iobj);
90 Py_DECREF(iobj);
91 }
92 if (ival == -1 && PyErr_Occurred()) {
93 goto exit;
94 }
95 i = ival;
96 }
97skip_optional:
Brett Cannon1eb32c22014-10-10 16:26:45 -040098 return_value = array_array_pop_impl(self, i);
99
100exit:
101 return return_value;
102}
103
104PyDoc_STRVAR(array_array_extend__doc__,
105"extend($self, bb, /)\n"
106"--\n"
107"\n"
108"Append items to the end of the array.");
109
110#define ARRAY_ARRAY_EXTEND_METHODDEF \
Erlend Egeberg Aasland75bf1072021-01-02 17:38:47 +0100111 {"extend", (PyCFunction)(void(*)(void))array_array_extend, METH_METHOD|METH_FASTCALL|METH_KEYWORDS, array_array_extend__doc__},
112
113static PyObject *
114array_array_extend_impl(arrayobject *self, PyTypeObject *cls, PyObject *bb);
115
116static PyObject *
117array_array_extend(arrayobject *self, PyTypeObject *cls, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
118{
119 PyObject *return_value = NULL;
120 static const char * const _keywords[] = {"", NULL};
121 static _PyArg_Parser _parser = {"O:extend", _keywords, 0};
122 PyObject *bb;
123
124 if (!_PyArg_ParseStackAndKeywords(args, nargs, kwnames, &_parser,
125 &bb)) {
126 goto exit;
127 }
128 return_value = array_array_extend_impl(self, cls, bb);
129
130exit:
131 return return_value;
132}
Brett Cannon1eb32c22014-10-10 16:26:45 -0400133
134PyDoc_STRVAR(array_array_insert__doc__,
135"insert($self, i, v, /)\n"
136"--\n"
137"\n"
138"Insert a new item v into the array before position i.");
139
140#define ARRAY_ARRAY_INSERT_METHODDEF \
Serhiy Storchaka4a934d42018-11-27 11:27:36 +0200141 {"insert", (PyCFunction)(void(*)(void))array_array_insert, METH_FASTCALL, array_array_insert__doc__},
Brett Cannon1eb32c22014-10-10 16:26:45 -0400142
143static PyObject *
144array_array_insert_impl(arrayobject *self, Py_ssize_t i, PyObject *v);
145
146static PyObject *
Serhiy Storchakaa5552f02017-12-15 13:11:11 +0200147array_array_insert(arrayobject *self, PyObject *const *args, Py_ssize_t nargs)
Brett Cannon1eb32c22014-10-10 16:26:45 -0400148{
149 PyObject *return_value = NULL;
150 Py_ssize_t i;
151 PyObject *v;
152
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200153 if (!_PyArg_CheckPositional("insert", nargs, 2, 2)) {
Victor Stinner259f0e42017-01-17 01:35:17 +0100154 goto exit;
155 }
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200156 {
157 Py_ssize_t ival = -1;
Serhiy Storchaka5f4b229d2020-05-28 10:33:45 +0300158 PyObject *iobj = _PyNumber_Index(args[0]);
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200159 if (iobj != NULL) {
160 ival = PyLong_AsSsize_t(iobj);
161 Py_DECREF(iobj);
162 }
163 if (ival == -1 && PyErr_Occurred()) {
164 goto exit;
165 }
166 i = ival;
167 }
168 v = args[1];
Brett Cannon1eb32c22014-10-10 16:26:45 -0400169 return_value = array_array_insert_impl(self, i, v);
170
171exit:
172 return return_value;
173}
174
175PyDoc_STRVAR(array_array_buffer_info__doc__,
176"buffer_info($self, /)\n"
177"--\n"
178"\n"
179"Return a tuple (address, length) giving the current memory address and the length in items of the buffer used to hold array\'s contents.\n"
180"\n"
181"The length should be multiplied by the itemsize attribute to calculate\n"
182"the buffer length in bytes.");
183
184#define ARRAY_ARRAY_BUFFER_INFO_METHODDEF \
185 {"buffer_info", (PyCFunction)array_array_buffer_info, METH_NOARGS, array_array_buffer_info__doc__},
186
187static PyObject *
188array_array_buffer_info_impl(arrayobject *self);
189
190static PyObject *
191array_array_buffer_info(arrayobject *self, PyObject *Py_UNUSED(ignored))
192{
193 return array_array_buffer_info_impl(self);
194}
195
196PyDoc_STRVAR(array_array_append__doc__,
197"append($self, v, /)\n"
198"--\n"
199"\n"
200"Append new value v to the end of the array.");
201
202#define ARRAY_ARRAY_APPEND_METHODDEF \
203 {"append", (PyCFunction)array_array_append, METH_O, array_array_append__doc__},
204
205PyDoc_STRVAR(array_array_byteswap__doc__,
206"byteswap($self, /)\n"
207"--\n"
208"\n"
209"Byteswap all items of the array.\n"
210"\n"
211"If the items in the array are not 1, 2, 4, or 8 bytes in size, RuntimeError is\n"
212"raised.");
213
214#define ARRAY_ARRAY_BYTESWAP_METHODDEF \
215 {"byteswap", (PyCFunction)array_array_byteswap, METH_NOARGS, array_array_byteswap__doc__},
216
217static PyObject *
218array_array_byteswap_impl(arrayobject *self);
219
220static PyObject *
221array_array_byteswap(arrayobject *self, PyObject *Py_UNUSED(ignored))
222{
223 return array_array_byteswap_impl(self);
224}
225
226PyDoc_STRVAR(array_array_reverse__doc__,
227"reverse($self, /)\n"
228"--\n"
229"\n"
230"Reverse the order of the items in the array.");
231
232#define ARRAY_ARRAY_REVERSE_METHODDEF \
233 {"reverse", (PyCFunction)array_array_reverse, METH_NOARGS, array_array_reverse__doc__},
234
235static PyObject *
236array_array_reverse_impl(arrayobject *self);
237
238static PyObject *
239array_array_reverse(arrayobject *self, PyObject *Py_UNUSED(ignored))
240{
241 return array_array_reverse_impl(self);
242}
243
244PyDoc_STRVAR(array_array_fromfile__doc__,
245"fromfile($self, f, n, /)\n"
246"--\n"
247"\n"
248"Read n objects from the file object f and append them to the end of the array.");
249
250#define ARRAY_ARRAY_FROMFILE_METHODDEF \
Serhiy Storchaka4a934d42018-11-27 11:27:36 +0200251 {"fromfile", (PyCFunction)(void(*)(void))array_array_fromfile, METH_FASTCALL, array_array_fromfile__doc__},
Brett Cannon1eb32c22014-10-10 16:26:45 -0400252
253static PyObject *
254array_array_fromfile_impl(arrayobject *self, PyObject *f, Py_ssize_t n);
255
256static PyObject *
Serhiy Storchakaa5552f02017-12-15 13:11:11 +0200257array_array_fromfile(arrayobject *self, PyObject *const *args, Py_ssize_t nargs)
Brett Cannon1eb32c22014-10-10 16:26:45 -0400258{
259 PyObject *return_value = NULL;
260 PyObject *f;
261 Py_ssize_t n;
262
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200263 if (!_PyArg_CheckPositional("fromfile", nargs, 2, 2)) {
Victor Stinner259f0e42017-01-17 01:35:17 +0100264 goto exit;
265 }
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200266 f = args[0];
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200267 {
268 Py_ssize_t ival = -1;
Serhiy Storchaka5f4b229d2020-05-28 10:33:45 +0300269 PyObject *iobj = _PyNumber_Index(args[1]);
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200270 if (iobj != NULL) {
271 ival = PyLong_AsSsize_t(iobj);
272 Py_DECREF(iobj);
273 }
274 if (ival == -1 && PyErr_Occurred()) {
275 goto exit;
276 }
277 n = ival;
278 }
Brett Cannon1eb32c22014-10-10 16:26:45 -0400279 return_value = array_array_fromfile_impl(self, f, n);
280
281exit:
282 return return_value;
283}
284
285PyDoc_STRVAR(array_array_tofile__doc__,
286"tofile($self, f, /)\n"
287"--\n"
288"\n"
289"Write all items (as machine values) to the file object f.");
290
291#define ARRAY_ARRAY_TOFILE_METHODDEF \
292 {"tofile", (PyCFunction)array_array_tofile, METH_O, array_array_tofile__doc__},
293
294PyDoc_STRVAR(array_array_fromlist__doc__,
295"fromlist($self, list, /)\n"
296"--\n"
297"\n"
298"Append items to array from list.");
299
300#define ARRAY_ARRAY_FROMLIST_METHODDEF \
301 {"fromlist", (PyCFunction)array_array_fromlist, METH_O, array_array_fromlist__doc__},
302
303PyDoc_STRVAR(array_array_tolist__doc__,
304"tolist($self, /)\n"
305"--\n"
306"\n"
307"Convert array to an ordinary list with the same items.");
308
309#define ARRAY_ARRAY_TOLIST_METHODDEF \
310 {"tolist", (PyCFunction)array_array_tolist, METH_NOARGS, array_array_tolist__doc__},
311
312static PyObject *
313array_array_tolist_impl(arrayobject *self);
314
315static PyObject *
316array_array_tolist(arrayobject *self, PyObject *Py_UNUSED(ignored))
317{
318 return array_array_tolist_impl(self);
319}
320
Brett Cannon1eb32c22014-10-10 16:26:45 -0400321PyDoc_STRVAR(array_array_frombytes__doc__,
322"frombytes($self, buffer, /)\n"
323"--\n"
324"\n"
325"Appends items from the string, interpreting it as an array of machine values, as if it had been read from a file using the fromfile() method).");
326
327#define ARRAY_ARRAY_FROMBYTES_METHODDEF \
Serhiy Storchaka92e8af62015-04-04 00:12:11 +0300328 {"frombytes", (PyCFunction)array_array_frombytes, METH_O, array_array_frombytes__doc__},
Brett Cannon1eb32c22014-10-10 16:26:45 -0400329
330static PyObject *
331array_array_frombytes_impl(arrayobject *self, Py_buffer *buffer);
332
333static PyObject *
Serhiy Storchaka92e8af62015-04-04 00:12:11 +0300334array_array_frombytes(arrayobject *self, PyObject *arg)
Brett Cannon1eb32c22014-10-10 16:26:45 -0400335{
336 PyObject *return_value = NULL;
337 Py_buffer buffer = {NULL, NULL};
338
Serhiy Storchaka32d96a22018-12-25 13:23:47 +0200339 if (PyObject_GetBuffer(arg, &buffer, PyBUF_SIMPLE) != 0) {
340 goto exit;
341 }
342 if (!PyBuffer_IsContiguous(&buffer, 'C')) {
Rémi Lapeyre4901fe22019-08-29 16:49:08 +0200343 _PyArg_BadArgument("frombytes", "argument", "contiguous buffer", arg);
Brett Cannon1eb32c22014-10-10 16:26:45 -0400344 goto exit;
Serhiy Storchaka5dee6552016-06-09 16:16:06 +0300345 }
Brett Cannon1eb32c22014-10-10 16:26:45 -0400346 return_value = array_array_frombytes_impl(self, &buffer);
347
348exit:
349 /* Cleanup for buffer */
Serhiy Storchaka5dee6552016-06-09 16:16:06 +0300350 if (buffer.obj) {
Brett Cannon1eb32c22014-10-10 16:26:45 -0400351 PyBuffer_Release(&buffer);
Serhiy Storchaka5dee6552016-06-09 16:16:06 +0300352 }
Brett Cannon1eb32c22014-10-10 16:26:45 -0400353
354 return return_value;
355}
356
357PyDoc_STRVAR(array_array_tobytes__doc__,
358"tobytes($self, /)\n"
359"--\n"
360"\n"
361"Convert the array to an array of machine values and return the bytes representation.");
362
363#define ARRAY_ARRAY_TOBYTES_METHODDEF \
364 {"tobytes", (PyCFunction)array_array_tobytes, METH_NOARGS, array_array_tobytes__doc__},
365
366static PyObject *
367array_array_tobytes_impl(arrayobject *self);
368
369static PyObject *
370array_array_tobytes(arrayobject *self, PyObject *Py_UNUSED(ignored))
371{
372 return array_array_tobytes_impl(self);
373}
374
Brett Cannon1eb32c22014-10-10 16:26:45 -0400375PyDoc_STRVAR(array_array_fromunicode__doc__,
376"fromunicode($self, ustr, /)\n"
377"--\n"
378"\n"
379"Extends this array with data from the unicode string ustr.\n"
380"\n"
381"The array must be a unicode type array; otherwise a ValueError is raised.\n"
382"Use array.frombytes(ustr.encode(...)) to append Unicode data to an array of\n"
383"some other type.");
384
385#define ARRAY_ARRAY_FROMUNICODE_METHODDEF \
Serhiy Storchaka92e8af62015-04-04 00:12:11 +0300386 {"fromunicode", (PyCFunction)array_array_fromunicode, METH_O, array_array_fromunicode__doc__},
Brett Cannon1eb32c22014-10-10 16:26:45 -0400387
388static PyObject *
Inada Naokid5d9a712020-05-11 15:37:25 +0900389array_array_fromunicode_impl(arrayobject *self, PyObject *ustr);
Brett Cannon1eb32c22014-10-10 16:26:45 -0400390
391static PyObject *
Serhiy Storchaka92e8af62015-04-04 00:12:11 +0300392array_array_fromunicode(arrayobject *self, PyObject *arg)
Brett Cannon1eb32c22014-10-10 16:26:45 -0400393{
394 PyObject *return_value = NULL;
Inada Naokid5d9a712020-05-11 15:37:25 +0900395 PyObject *ustr;
Brett Cannon1eb32c22014-10-10 16:26:45 -0400396
Inada Naokid5d9a712020-05-11 15:37:25 +0900397 if (!PyUnicode_Check(arg)) {
398 _PyArg_BadArgument("fromunicode", "argument", "str", arg);
Brett Cannon1eb32c22014-10-10 16:26:45 -0400399 goto exit;
Serhiy Storchaka5dee6552016-06-09 16:16:06 +0300400 }
Inada Naokid5d9a712020-05-11 15:37:25 +0900401 if (PyUnicode_READY(arg) == -1) {
402 goto exit;
403 }
404 ustr = arg;
405 return_value = array_array_fromunicode_impl(self, ustr);
Brett Cannon1eb32c22014-10-10 16:26:45 -0400406
407exit:
408 return return_value;
409}
410
411PyDoc_STRVAR(array_array_tounicode__doc__,
412"tounicode($self, /)\n"
413"--\n"
414"\n"
415"Extends this array with data from the unicode string ustr.\n"
416"\n"
417"Convert the array to a unicode string. The array must be a unicode type array;\n"
418"otherwise a ValueError is raised. Use array.tobytes().decode() to obtain a\n"
419"unicode string from an array of some other type.");
420
421#define ARRAY_ARRAY_TOUNICODE_METHODDEF \
422 {"tounicode", (PyCFunction)array_array_tounicode, METH_NOARGS, array_array_tounicode__doc__},
423
424static PyObject *
425array_array_tounicode_impl(arrayobject *self);
426
427static PyObject *
428array_array_tounicode(arrayobject *self, PyObject *Py_UNUSED(ignored))
429{
430 return array_array_tounicode_impl(self);
431}
432
433PyDoc_STRVAR(array_array___sizeof____doc__,
434"__sizeof__($self, /)\n"
435"--\n"
436"\n"
437"Size of the array in memory, in bytes.");
438
439#define ARRAY_ARRAY___SIZEOF___METHODDEF \
440 {"__sizeof__", (PyCFunction)array_array___sizeof__, METH_NOARGS, array_array___sizeof____doc__},
441
442static PyObject *
443array_array___sizeof___impl(arrayobject *self);
444
445static PyObject *
446array_array___sizeof__(arrayobject *self, PyObject *Py_UNUSED(ignored))
447{
448 return array_array___sizeof___impl(self);
449}
450
451PyDoc_STRVAR(array__array_reconstructor__doc__,
452"_array_reconstructor($module, arraytype, typecode, mformat_code, items,\n"
453" /)\n"
454"--\n"
455"\n"
456"Internal. Used for pickling support.");
457
458#define ARRAY__ARRAY_RECONSTRUCTOR_METHODDEF \
Serhiy Storchaka4a934d42018-11-27 11:27:36 +0200459 {"_array_reconstructor", (PyCFunction)(void(*)(void))array__array_reconstructor, METH_FASTCALL, array__array_reconstructor__doc__},
Brett Cannon1eb32c22014-10-10 16:26:45 -0400460
461static PyObject *
Serhiy Storchaka1a2b24f2016-07-07 17:35:15 +0300462array__array_reconstructor_impl(PyObject *module, PyTypeObject *arraytype,
Larry Hastings89964c42015-04-14 18:07:59 -0400463 int typecode,
464 enum machine_format_code mformat_code,
465 PyObject *items);
Brett Cannon1eb32c22014-10-10 16:26:45 -0400466
467static PyObject *
Serhiy Storchakaa5552f02017-12-15 13:11:11 +0200468array__array_reconstructor(PyObject *module, PyObject *const *args, Py_ssize_t nargs)
Brett Cannon1eb32c22014-10-10 16:26:45 -0400469{
470 PyObject *return_value = NULL;
471 PyTypeObject *arraytype;
472 int typecode;
Larry Hastingsdfbeb162014-10-13 10:39:41 +0100473 enum machine_format_code mformat_code;
Brett Cannon1eb32c22014-10-10 16:26:45 -0400474 PyObject *items;
475
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200476 if (!_PyArg_CheckPositional("_array_reconstructor", nargs, 4, 4)) {
Victor Stinner259f0e42017-01-17 01:35:17 +0100477 goto exit;
478 }
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200479 arraytype = (PyTypeObject *)args[0];
480 if (!PyUnicode_Check(args[1])) {
Rémi Lapeyre4901fe22019-08-29 16:49:08 +0200481 _PyArg_BadArgument("_array_reconstructor", "argument 2", "a unicode character", args[1]);
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200482 goto exit;
483 }
484 if (PyUnicode_READY(args[1])) {
485 goto exit;
486 }
487 if (PyUnicode_GET_LENGTH(args[1]) != 1) {
Rémi Lapeyre4901fe22019-08-29 16:49:08 +0200488 _PyArg_BadArgument("_array_reconstructor", "argument 2", "a unicode character", args[1]);
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200489 goto exit;
490 }
491 typecode = PyUnicode_READ_CHAR(args[1], 0);
Serhiy Storchaka4fa95912019-01-11 16:01:14 +0200492 mformat_code = _PyLong_AsInt(args[2]);
493 if (mformat_code == -1 && PyErr_Occurred()) {
494 goto exit;
495 }
496 items = args[3];
Brett Cannon1eb32c22014-10-10 16:26:45 -0400497 return_value = array__array_reconstructor_impl(module, arraytype, typecode, mformat_code, items);
498
499exit:
500 return return_value;
501}
502
503PyDoc_STRVAR(array_array___reduce_ex____doc__,
504"__reduce_ex__($self, value, /)\n"
505"--\n"
506"\n"
507"Return state information for pickling.");
508
509#define ARRAY_ARRAY___REDUCE_EX___METHODDEF \
510 {"__reduce_ex__", (PyCFunction)array_array___reduce_ex__, METH_O, array_array___reduce_ex____doc__},
511
512PyDoc_STRVAR(array_arrayiterator___reduce____doc__,
513"__reduce__($self, /)\n"
514"--\n"
515"\n"
516"Return state information for pickling.");
517
518#define ARRAY_ARRAYITERATOR___REDUCE___METHODDEF \
519 {"__reduce__", (PyCFunction)array_arrayiterator___reduce__, METH_NOARGS, array_arrayiterator___reduce____doc__},
520
521static PyObject *
522array_arrayiterator___reduce___impl(arrayiterobject *self);
523
524static PyObject *
525array_arrayiterator___reduce__(arrayiterobject *self, PyObject *Py_UNUSED(ignored))
526{
527 return array_arrayiterator___reduce___impl(self);
528}
529
530PyDoc_STRVAR(array_arrayiterator___setstate____doc__,
531"__setstate__($self, state, /)\n"
532"--\n"
533"\n"
534"Set state information for unpickling.");
535
536#define ARRAY_ARRAYITERATOR___SETSTATE___METHODDEF \
537 {"__setstate__", (PyCFunction)array_arrayiterator___setstate__, METH_O, array_arrayiterator___setstate____doc__},
Erlend Egeberg Aasland75bf1072021-01-02 17:38:47 +0100538/*[clinic end generated code: output=a7f71a18b994c88f input=a9049054013a1b77]*/