1 /*[clinic input]
2 preserve
3 [clinic start generated code]*/
4 
5 PyDoc_STRVAR(_io_IncrementalNewlineDecoder___init____doc__,
6 "IncrementalNewlineDecoder(decoder, translate, errors=\'strict\')\n"
7 "--\n"
8 "\n"
9 "Codec used when reading a file in universal newlines mode.\n"
10 "\n"
11 "It wraps another incremental decoder, translating \\r\\n and \\r into \\n.\n"
12 "It also records the types of newlines encountered.  When used with\n"
13 "translate=False, it ensures that the newline sequence is returned in\n"
14 "one piece. When used with decoder=None, it expects unicode strings as\n"
15 "decode input and translates newlines without first invoking an external\n"
16 "decoder.");
17 
18 static int
19 _io_IncrementalNewlineDecoder___init___impl(nldecoder_object *self,
20                                             PyObject *decoder, int translate,
21                                             PyObject *errors);
22 
23 static int
_io_IncrementalNewlineDecoder___init__(PyObject * self,PyObject * args,PyObject * kwargs)24 _io_IncrementalNewlineDecoder___init__(PyObject *self, PyObject *args, PyObject *kwargs)
25 {
26     int return_value = -1;
27     static const char * const _keywords[] = {"decoder", "translate", "errors", NULL};
28     static _PyArg_Parser _parser = {NULL, _keywords, "IncrementalNewlineDecoder", 0};
29     PyObject *argsbuf[3];
30     PyObject * const *fastargs;
31     Py_ssize_t nargs = PyTuple_GET_SIZE(args);
32     Py_ssize_t noptargs = nargs + (kwargs ? PyDict_GET_SIZE(kwargs) : 0) - 2;
33     PyObject *decoder;
34     int translate;
35     PyObject *errors = NULL;
36 
37     fastargs = _PyArg_UnpackKeywords(_PyTuple_CAST(args)->ob_item, nargs, kwargs, NULL, &_parser, 2, 3, 0, argsbuf);
38     if (!fastargs) {
39         goto exit;
40     }
41     decoder = fastargs[0];
42     translate = _PyLong_AsInt(fastargs[1]);
43     if (translate == -1 && PyErr_Occurred()) {
44         goto exit;
45     }
46     if (!noptargs) {
47         goto skip_optional_pos;
48     }
49     errors = fastargs[2];
50 skip_optional_pos:
51     return_value = _io_IncrementalNewlineDecoder___init___impl((nldecoder_object *)self, decoder, translate, errors);
52 
53 exit:
54     return return_value;
55 }
56 
57 PyDoc_STRVAR(_io_IncrementalNewlineDecoder_decode__doc__,
58 "decode($self, /, input, final=False)\n"
59 "--\n"
60 "\n");
61 
62 #define _IO_INCREMENTALNEWLINEDECODER_DECODE_METHODDEF    \
63     {"decode", _PyCFunction_CAST(_io_IncrementalNewlineDecoder_decode), METH_FASTCALL|METH_KEYWORDS, _io_IncrementalNewlineDecoder_decode__doc__},
64 
65 static PyObject *
66 _io_IncrementalNewlineDecoder_decode_impl(nldecoder_object *self,
67                                           PyObject *input, int final);
68 
69 static PyObject *
_io_IncrementalNewlineDecoder_decode(nldecoder_object * self,PyObject * const * args,Py_ssize_t nargs,PyObject * kwnames)70 _io_IncrementalNewlineDecoder_decode(nldecoder_object *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
71 {
72     PyObject *return_value = NULL;
73     static const char * const _keywords[] = {"input", "final", NULL};
74     static _PyArg_Parser _parser = {NULL, _keywords, "decode", 0};
75     PyObject *argsbuf[2];
76     Py_ssize_t noptargs = nargs + (kwnames ? PyTuple_GET_SIZE(kwnames) : 0) - 1;
77     PyObject *input;
78     int final = 0;
79 
80     args = _PyArg_UnpackKeywords(args, nargs, NULL, kwnames, &_parser, 1, 2, 0, argsbuf);
81     if (!args) {
82         goto exit;
83     }
84     input = args[0];
85     if (!noptargs) {
86         goto skip_optional_pos;
87     }
88     final = _PyLong_AsInt(args[1]);
89     if (final == -1 && PyErr_Occurred()) {
90         goto exit;
91     }
92 skip_optional_pos:
93     return_value = _io_IncrementalNewlineDecoder_decode_impl(self, input, final);
94 
95 exit:
96     return return_value;
97 }
98 
99 PyDoc_STRVAR(_io_IncrementalNewlineDecoder_getstate__doc__,
100 "getstate($self, /)\n"
101 "--\n"
102 "\n");
103 
104 #define _IO_INCREMENTALNEWLINEDECODER_GETSTATE_METHODDEF    \
105     {"getstate", (PyCFunction)_io_IncrementalNewlineDecoder_getstate, METH_NOARGS, _io_IncrementalNewlineDecoder_getstate__doc__},
106 
107 static PyObject *
108 _io_IncrementalNewlineDecoder_getstate_impl(nldecoder_object *self);
109 
110 static PyObject *
_io_IncrementalNewlineDecoder_getstate(nldecoder_object * self,PyObject * Py_UNUSED (ignored))111 _io_IncrementalNewlineDecoder_getstate(nldecoder_object *self, PyObject *Py_UNUSED(ignored))
112 {
113     return _io_IncrementalNewlineDecoder_getstate_impl(self);
114 }
115 
116 PyDoc_STRVAR(_io_IncrementalNewlineDecoder_setstate__doc__,
117 "setstate($self, state, /)\n"
118 "--\n"
119 "\n");
120 
121 #define _IO_INCREMENTALNEWLINEDECODER_SETSTATE_METHODDEF    \
122     {"setstate", (PyCFunction)_io_IncrementalNewlineDecoder_setstate, METH_O, _io_IncrementalNewlineDecoder_setstate__doc__},
123 
124 PyDoc_STRVAR(_io_IncrementalNewlineDecoder_reset__doc__,
125 "reset($self, /)\n"
126 "--\n"
127 "\n");
128 
129 #define _IO_INCREMENTALNEWLINEDECODER_RESET_METHODDEF    \
130     {"reset", (PyCFunction)_io_IncrementalNewlineDecoder_reset, METH_NOARGS, _io_IncrementalNewlineDecoder_reset__doc__},
131 
132 static PyObject *
133 _io_IncrementalNewlineDecoder_reset_impl(nldecoder_object *self);
134 
135 static PyObject *
_io_IncrementalNewlineDecoder_reset(nldecoder_object * self,PyObject * Py_UNUSED (ignored))136 _io_IncrementalNewlineDecoder_reset(nldecoder_object *self, PyObject *Py_UNUSED(ignored))
137 {
138     return _io_IncrementalNewlineDecoder_reset_impl(self);
139 }
140 
141 PyDoc_STRVAR(_io_TextIOWrapper___init____doc__,
142 "TextIOWrapper(buffer, encoding=None, errors=None, newline=None,\n"
143 "              line_buffering=False, write_through=False)\n"
144 "--\n"
145 "\n"
146 "Character and line based layer over a BufferedIOBase object, buffer.\n"
147 "\n"
148 "encoding gives the name of the encoding that the stream will be\n"
149 "decoded or encoded with. It defaults to locale.getencoding().\n"
150 "\n"
151 "errors determines the strictness of encoding and decoding (see\n"
152 "help(codecs.Codec) or the documentation for codecs.register) and\n"
153 "defaults to \"strict\".\n"
154 "\n"
155 "newline controls how line endings are handled. It can be None, \'\',\n"
156 "\'\\n\', \'\\r\', and \'\\r\\n\'.  It works as follows:\n"
157 "\n"
158 "* On input, if newline is None, universal newlines mode is\n"
159 "  enabled. Lines in the input can end in \'\\n\', \'\\r\', or \'\\r\\n\', and\n"
160 "  these are translated into \'\\n\' before being returned to the\n"
161 "  caller. If it is \'\', universal newline mode is enabled, but line\n"
162 "  endings are returned to the caller untranslated. If it has any of\n"
163 "  the other legal values, input lines are only terminated by the given\n"
164 "  string, and the line ending is returned to the caller untranslated.\n"
165 "\n"
166 "* On output, if newline is None, any \'\\n\' characters written are\n"
167 "  translated to the system default line separator, os.linesep. If\n"
168 "  newline is \'\' or \'\\n\', no translation takes place. If newline is any\n"
169 "  of the other legal values, any \'\\n\' characters written are translated\n"
170 "  to the given string.\n"
171 "\n"
172 "If line_buffering is True, a call to flush is implied when a call to\n"
173 "write contains a newline character.");
174 
175 static int
176 _io_TextIOWrapper___init___impl(textio *self, PyObject *buffer,
177                                 const char *encoding, PyObject *errors,
178                                 const char *newline, int line_buffering,
179                                 int write_through);
180 
181 static int
_io_TextIOWrapper___init__(PyObject * self,PyObject * args,PyObject * kwargs)182 _io_TextIOWrapper___init__(PyObject *self, PyObject *args, PyObject *kwargs)
183 {
184     int return_value = -1;
185     static const char * const _keywords[] = {"buffer", "encoding", "errors", "newline", "line_buffering", "write_through", NULL};
186     static _PyArg_Parser _parser = {NULL, _keywords, "TextIOWrapper", 0};
187     PyObject *argsbuf[6];
188     PyObject * const *fastargs;
189     Py_ssize_t nargs = PyTuple_GET_SIZE(args);
190     Py_ssize_t noptargs = nargs + (kwargs ? PyDict_GET_SIZE(kwargs) : 0) - 1;
191     PyObject *buffer;
192     const char *encoding = NULL;
193     PyObject *errors = Py_None;
194     const char *newline = NULL;
195     int line_buffering = 0;
196     int write_through = 0;
197 
198     fastargs = _PyArg_UnpackKeywords(_PyTuple_CAST(args)->ob_item, nargs, kwargs, NULL, &_parser, 1, 6, 0, argsbuf);
199     if (!fastargs) {
200         goto exit;
201     }
202     buffer = fastargs[0];
203     if (!noptargs) {
204         goto skip_optional_pos;
205     }
206     if (fastargs[1]) {
207         if (fastargs[1] == Py_None) {
208             encoding = NULL;
209         }
210         else if (PyUnicode_Check(fastargs[1])) {
211             Py_ssize_t encoding_length;
212             encoding = PyUnicode_AsUTF8AndSize(fastargs[1], &encoding_length);
213             if (encoding == NULL) {
214                 goto exit;
215             }
216             if (strlen(encoding) != (size_t)encoding_length) {
217                 PyErr_SetString(PyExc_ValueError, "embedded null character");
218                 goto exit;
219             }
220         }
221         else {
222             _PyArg_BadArgument("TextIOWrapper", "argument 'encoding'", "str or None", fastargs[1]);
223             goto exit;
224         }
225         if (!--noptargs) {
226             goto skip_optional_pos;
227         }
228     }
229     if (fastargs[2]) {
230         errors = fastargs[2];
231         if (!--noptargs) {
232             goto skip_optional_pos;
233         }
234     }
235     if (fastargs[3]) {
236         if (fastargs[3] == Py_None) {
237             newline = NULL;
238         }
239         else if (PyUnicode_Check(fastargs[3])) {
240             Py_ssize_t newline_length;
241             newline = PyUnicode_AsUTF8AndSize(fastargs[3], &newline_length);
242             if (newline == NULL) {
243                 goto exit;
244             }
245             if (strlen(newline) != (size_t)newline_length) {
246                 PyErr_SetString(PyExc_ValueError, "embedded null character");
247                 goto exit;
248             }
249         }
250         else {
251             _PyArg_BadArgument("TextIOWrapper", "argument 'newline'", "str or None", fastargs[3]);
252             goto exit;
253         }
254         if (!--noptargs) {
255             goto skip_optional_pos;
256         }
257     }
258     if (fastargs[4]) {
259         line_buffering = _PyLong_AsInt(fastargs[4]);
260         if (line_buffering == -1 && PyErr_Occurred()) {
261             goto exit;
262         }
263         if (!--noptargs) {
264             goto skip_optional_pos;
265         }
266     }
267     write_through = _PyLong_AsInt(fastargs[5]);
268     if (write_through == -1 && PyErr_Occurred()) {
269         goto exit;
270     }
271 skip_optional_pos:
272     return_value = _io_TextIOWrapper___init___impl((textio *)self, buffer, encoding, errors, newline, line_buffering, write_through);
273 
274 exit:
275     return return_value;
276 }
277 
278 PyDoc_STRVAR(_io_TextIOWrapper_reconfigure__doc__,
279 "reconfigure($self, /, *, encoding=None, errors=None, newline=None,\n"
280 "            line_buffering=None, write_through=None)\n"
281 "--\n"
282 "\n"
283 "Reconfigure the text stream with new parameters.\n"
284 "\n"
285 "This also does an implicit stream flush.");
286 
287 #define _IO_TEXTIOWRAPPER_RECONFIGURE_METHODDEF    \
288     {"reconfigure", _PyCFunction_CAST(_io_TextIOWrapper_reconfigure), METH_FASTCALL|METH_KEYWORDS, _io_TextIOWrapper_reconfigure__doc__},
289 
290 static PyObject *
291 _io_TextIOWrapper_reconfigure_impl(textio *self, PyObject *encoding,
292                                    PyObject *errors, PyObject *newline_obj,
293                                    PyObject *line_buffering_obj,
294                                    PyObject *write_through_obj);
295 
296 static PyObject *
_io_TextIOWrapper_reconfigure(textio * self,PyObject * const * args,Py_ssize_t nargs,PyObject * kwnames)297 _io_TextIOWrapper_reconfigure(textio *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
298 {
299     PyObject *return_value = NULL;
300     static const char * const _keywords[] = {"encoding", "errors", "newline", "line_buffering", "write_through", NULL};
301     static _PyArg_Parser _parser = {NULL, _keywords, "reconfigure", 0};
302     PyObject *argsbuf[5];
303     Py_ssize_t noptargs = nargs + (kwnames ? PyTuple_GET_SIZE(kwnames) : 0) - 0;
304     PyObject *encoding = Py_None;
305     PyObject *errors = Py_None;
306     PyObject *newline_obj = NULL;
307     PyObject *line_buffering_obj = Py_None;
308     PyObject *write_through_obj = Py_None;
309 
310     args = _PyArg_UnpackKeywords(args, nargs, NULL, kwnames, &_parser, 0, 0, 0, argsbuf);
311     if (!args) {
312         goto exit;
313     }
314     if (!noptargs) {
315         goto skip_optional_kwonly;
316     }
317     if (args[0]) {
318         encoding = args[0];
319         if (!--noptargs) {
320             goto skip_optional_kwonly;
321         }
322     }
323     if (args[1]) {
324         errors = args[1];
325         if (!--noptargs) {
326             goto skip_optional_kwonly;
327         }
328     }
329     if (args[2]) {
330         newline_obj = args[2];
331         if (!--noptargs) {
332             goto skip_optional_kwonly;
333         }
334     }
335     if (args[3]) {
336         line_buffering_obj = args[3];
337         if (!--noptargs) {
338             goto skip_optional_kwonly;
339         }
340     }
341     write_through_obj = args[4];
342 skip_optional_kwonly:
343     return_value = _io_TextIOWrapper_reconfigure_impl(self, encoding, errors, newline_obj, line_buffering_obj, write_through_obj);
344 
345 exit:
346     return return_value;
347 }
348 
349 PyDoc_STRVAR(_io_TextIOWrapper_detach__doc__,
350 "detach($self, /)\n"
351 "--\n"
352 "\n");
353 
354 #define _IO_TEXTIOWRAPPER_DETACH_METHODDEF    \
355     {"detach", (PyCFunction)_io_TextIOWrapper_detach, METH_NOARGS, _io_TextIOWrapper_detach__doc__},
356 
357 static PyObject *
358 _io_TextIOWrapper_detach_impl(textio *self);
359 
360 static PyObject *
_io_TextIOWrapper_detach(textio * self,PyObject * Py_UNUSED (ignored))361 _io_TextIOWrapper_detach(textio *self, PyObject *Py_UNUSED(ignored))
362 {
363     return _io_TextIOWrapper_detach_impl(self);
364 }
365 
366 PyDoc_STRVAR(_io_TextIOWrapper_write__doc__,
367 "write($self, text, /)\n"
368 "--\n"
369 "\n");
370 
371 #define _IO_TEXTIOWRAPPER_WRITE_METHODDEF    \
372     {"write", (PyCFunction)_io_TextIOWrapper_write, METH_O, _io_TextIOWrapper_write__doc__},
373 
374 static PyObject *
375 _io_TextIOWrapper_write_impl(textio *self, PyObject *text);
376 
377 static PyObject *
_io_TextIOWrapper_write(textio * self,PyObject * arg)378 _io_TextIOWrapper_write(textio *self, PyObject *arg)
379 {
380     PyObject *return_value = NULL;
381     PyObject *text;
382 
383     if (!PyUnicode_Check(arg)) {
384         _PyArg_BadArgument("write", "argument", "str", arg);
385         goto exit;
386     }
387     if (PyUnicode_READY(arg) == -1) {
388         goto exit;
389     }
390     text = arg;
391     return_value = _io_TextIOWrapper_write_impl(self, text);
392 
393 exit:
394     return return_value;
395 }
396 
397 PyDoc_STRVAR(_io_TextIOWrapper_read__doc__,
398 "read($self, size=-1, /)\n"
399 "--\n"
400 "\n");
401 
402 #define _IO_TEXTIOWRAPPER_READ_METHODDEF    \
403     {"read", _PyCFunction_CAST(_io_TextIOWrapper_read), METH_FASTCALL, _io_TextIOWrapper_read__doc__},
404 
405 static PyObject *
406 _io_TextIOWrapper_read_impl(textio *self, Py_ssize_t n);
407 
408 static PyObject *
_io_TextIOWrapper_read(textio * self,PyObject * const * args,Py_ssize_t nargs)409 _io_TextIOWrapper_read(textio *self, PyObject *const *args, Py_ssize_t nargs)
410 {
411     PyObject *return_value = NULL;
412     Py_ssize_t n = -1;
413 
414     if (!_PyArg_CheckPositional("read", nargs, 0, 1)) {
415         goto exit;
416     }
417     if (nargs < 1) {
418         goto skip_optional;
419     }
420     if (!_Py_convert_optional_to_ssize_t(args[0], &n)) {
421         goto exit;
422     }
423 skip_optional:
424     return_value = _io_TextIOWrapper_read_impl(self, n);
425 
426 exit:
427     return return_value;
428 }
429 
430 PyDoc_STRVAR(_io_TextIOWrapper_readline__doc__,
431 "readline($self, size=-1, /)\n"
432 "--\n"
433 "\n");
434 
435 #define _IO_TEXTIOWRAPPER_READLINE_METHODDEF    \
436     {"readline", _PyCFunction_CAST(_io_TextIOWrapper_readline), METH_FASTCALL, _io_TextIOWrapper_readline__doc__},
437 
438 static PyObject *
439 _io_TextIOWrapper_readline_impl(textio *self, Py_ssize_t size);
440 
441 static PyObject *
_io_TextIOWrapper_readline(textio * self,PyObject * const * args,Py_ssize_t nargs)442 _io_TextIOWrapper_readline(textio *self, PyObject *const *args, Py_ssize_t nargs)
443 {
444     PyObject *return_value = NULL;
445     Py_ssize_t size = -1;
446 
447     if (!_PyArg_CheckPositional("readline", nargs, 0, 1)) {
448         goto exit;
449     }
450     if (nargs < 1) {
451         goto skip_optional;
452     }
453     {
454         Py_ssize_t ival = -1;
455         PyObject *iobj = _PyNumber_Index(args[0]);
456         if (iobj != NULL) {
457             ival = PyLong_AsSsize_t(iobj);
458             Py_DECREF(iobj);
459         }
460         if (ival == -1 && PyErr_Occurred()) {
461             goto exit;
462         }
463         size = ival;
464     }
465 skip_optional:
466     return_value = _io_TextIOWrapper_readline_impl(self, size);
467 
468 exit:
469     return return_value;
470 }
471 
472 PyDoc_STRVAR(_io_TextIOWrapper_seek__doc__,
473 "seek($self, cookie, whence=0, /)\n"
474 "--\n"
475 "\n");
476 
477 #define _IO_TEXTIOWRAPPER_SEEK_METHODDEF    \
478     {"seek", _PyCFunction_CAST(_io_TextIOWrapper_seek), METH_FASTCALL, _io_TextIOWrapper_seek__doc__},
479 
480 static PyObject *
481 _io_TextIOWrapper_seek_impl(textio *self, PyObject *cookieObj, int whence);
482 
483 static PyObject *
_io_TextIOWrapper_seek(textio * self,PyObject * const * args,Py_ssize_t nargs)484 _io_TextIOWrapper_seek(textio *self, PyObject *const *args, Py_ssize_t nargs)
485 {
486     PyObject *return_value = NULL;
487     PyObject *cookieObj;
488     int whence = 0;
489 
490     if (!_PyArg_CheckPositional("seek", nargs, 1, 2)) {
491         goto exit;
492     }
493     cookieObj = args[0];
494     if (nargs < 2) {
495         goto skip_optional;
496     }
497     whence = _PyLong_AsInt(args[1]);
498     if (whence == -1 && PyErr_Occurred()) {
499         goto exit;
500     }
501 skip_optional:
502     return_value = _io_TextIOWrapper_seek_impl(self, cookieObj, whence);
503 
504 exit:
505     return return_value;
506 }
507 
508 PyDoc_STRVAR(_io_TextIOWrapper_tell__doc__,
509 "tell($self, /)\n"
510 "--\n"
511 "\n");
512 
513 #define _IO_TEXTIOWRAPPER_TELL_METHODDEF    \
514     {"tell", (PyCFunction)_io_TextIOWrapper_tell, METH_NOARGS, _io_TextIOWrapper_tell__doc__},
515 
516 static PyObject *
517 _io_TextIOWrapper_tell_impl(textio *self);
518 
519 static PyObject *
_io_TextIOWrapper_tell(textio * self,PyObject * Py_UNUSED (ignored))520 _io_TextIOWrapper_tell(textio *self, PyObject *Py_UNUSED(ignored))
521 {
522     return _io_TextIOWrapper_tell_impl(self);
523 }
524 
525 PyDoc_STRVAR(_io_TextIOWrapper_truncate__doc__,
526 "truncate($self, pos=None, /)\n"
527 "--\n"
528 "\n");
529 
530 #define _IO_TEXTIOWRAPPER_TRUNCATE_METHODDEF    \
531     {"truncate", _PyCFunction_CAST(_io_TextIOWrapper_truncate), METH_FASTCALL, _io_TextIOWrapper_truncate__doc__},
532 
533 static PyObject *
534 _io_TextIOWrapper_truncate_impl(textio *self, PyObject *pos);
535 
536 static PyObject *
_io_TextIOWrapper_truncate(textio * self,PyObject * const * args,Py_ssize_t nargs)537 _io_TextIOWrapper_truncate(textio *self, PyObject *const *args, Py_ssize_t nargs)
538 {
539     PyObject *return_value = NULL;
540     PyObject *pos = Py_None;
541 
542     if (!_PyArg_CheckPositional("truncate", nargs, 0, 1)) {
543         goto exit;
544     }
545     if (nargs < 1) {
546         goto skip_optional;
547     }
548     pos = args[0];
549 skip_optional:
550     return_value = _io_TextIOWrapper_truncate_impl(self, pos);
551 
552 exit:
553     return return_value;
554 }
555 
556 PyDoc_STRVAR(_io_TextIOWrapper_fileno__doc__,
557 "fileno($self, /)\n"
558 "--\n"
559 "\n");
560 
561 #define _IO_TEXTIOWRAPPER_FILENO_METHODDEF    \
562     {"fileno", (PyCFunction)_io_TextIOWrapper_fileno, METH_NOARGS, _io_TextIOWrapper_fileno__doc__},
563 
564 static PyObject *
565 _io_TextIOWrapper_fileno_impl(textio *self);
566 
567 static PyObject *
_io_TextIOWrapper_fileno(textio * self,PyObject * Py_UNUSED (ignored))568 _io_TextIOWrapper_fileno(textio *self, PyObject *Py_UNUSED(ignored))
569 {
570     return _io_TextIOWrapper_fileno_impl(self);
571 }
572 
573 PyDoc_STRVAR(_io_TextIOWrapper_seekable__doc__,
574 "seekable($self, /)\n"
575 "--\n"
576 "\n");
577 
578 #define _IO_TEXTIOWRAPPER_SEEKABLE_METHODDEF    \
579     {"seekable", (PyCFunction)_io_TextIOWrapper_seekable, METH_NOARGS, _io_TextIOWrapper_seekable__doc__},
580 
581 static PyObject *
582 _io_TextIOWrapper_seekable_impl(textio *self);
583 
584 static PyObject *
_io_TextIOWrapper_seekable(textio * self,PyObject * Py_UNUSED (ignored))585 _io_TextIOWrapper_seekable(textio *self, PyObject *Py_UNUSED(ignored))
586 {
587     return _io_TextIOWrapper_seekable_impl(self);
588 }
589 
590 PyDoc_STRVAR(_io_TextIOWrapper_readable__doc__,
591 "readable($self, /)\n"
592 "--\n"
593 "\n");
594 
595 #define _IO_TEXTIOWRAPPER_READABLE_METHODDEF    \
596     {"readable", (PyCFunction)_io_TextIOWrapper_readable, METH_NOARGS, _io_TextIOWrapper_readable__doc__},
597 
598 static PyObject *
599 _io_TextIOWrapper_readable_impl(textio *self);
600 
601 static PyObject *
_io_TextIOWrapper_readable(textio * self,PyObject * Py_UNUSED (ignored))602 _io_TextIOWrapper_readable(textio *self, PyObject *Py_UNUSED(ignored))
603 {
604     return _io_TextIOWrapper_readable_impl(self);
605 }
606 
607 PyDoc_STRVAR(_io_TextIOWrapper_writable__doc__,
608 "writable($self, /)\n"
609 "--\n"
610 "\n");
611 
612 #define _IO_TEXTIOWRAPPER_WRITABLE_METHODDEF    \
613     {"writable", (PyCFunction)_io_TextIOWrapper_writable, METH_NOARGS, _io_TextIOWrapper_writable__doc__},
614 
615 static PyObject *
616 _io_TextIOWrapper_writable_impl(textio *self);
617 
618 static PyObject *
_io_TextIOWrapper_writable(textio * self,PyObject * Py_UNUSED (ignored))619 _io_TextIOWrapper_writable(textio *self, PyObject *Py_UNUSED(ignored))
620 {
621     return _io_TextIOWrapper_writable_impl(self);
622 }
623 
624 PyDoc_STRVAR(_io_TextIOWrapper_isatty__doc__,
625 "isatty($self, /)\n"
626 "--\n"
627 "\n");
628 
629 #define _IO_TEXTIOWRAPPER_ISATTY_METHODDEF    \
630     {"isatty", (PyCFunction)_io_TextIOWrapper_isatty, METH_NOARGS, _io_TextIOWrapper_isatty__doc__},
631 
632 static PyObject *
633 _io_TextIOWrapper_isatty_impl(textio *self);
634 
635 static PyObject *
_io_TextIOWrapper_isatty(textio * self,PyObject * Py_UNUSED (ignored))636 _io_TextIOWrapper_isatty(textio *self, PyObject *Py_UNUSED(ignored))
637 {
638     return _io_TextIOWrapper_isatty_impl(self);
639 }
640 
641 PyDoc_STRVAR(_io_TextIOWrapper_flush__doc__,
642 "flush($self, /)\n"
643 "--\n"
644 "\n");
645 
646 #define _IO_TEXTIOWRAPPER_FLUSH_METHODDEF    \
647     {"flush", (PyCFunction)_io_TextIOWrapper_flush, METH_NOARGS, _io_TextIOWrapper_flush__doc__},
648 
649 static PyObject *
650 _io_TextIOWrapper_flush_impl(textio *self);
651 
652 static PyObject *
_io_TextIOWrapper_flush(textio * self,PyObject * Py_UNUSED (ignored))653 _io_TextIOWrapper_flush(textio *self, PyObject *Py_UNUSED(ignored))
654 {
655     return _io_TextIOWrapper_flush_impl(self);
656 }
657 
658 PyDoc_STRVAR(_io_TextIOWrapper_close__doc__,
659 "close($self, /)\n"
660 "--\n"
661 "\n");
662 
663 #define _IO_TEXTIOWRAPPER_CLOSE_METHODDEF    \
664     {"close", (PyCFunction)_io_TextIOWrapper_close, METH_NOARGS, _io_TextIOWrapper_close__doc__},
665 
666 static PyObject *
667 _io_TextIOWrapper_close_impl(textio *self);
668 
669 static PyObject *
_io_TextIOWrapper_close(textio * self,PyObject * Py_UNUSED (ignored))670 _io_TextIOWrapper_close(textio *self, PyObject *Py_UNUSED(ignored))
671 {
672     return _io_TextIOWrapper_close_impl(self);
673 }
674 /*[clinic end generated code: output=bb78b568b24759d6 input=a9049054013a1b77]*/
675