mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
bpo-36523: Add docstring to io.IOBase.writelines (GH-12683)
This commit is contained in:
parent
662ebd2ab2
commit
ab86521a9d
4 changed files with 18 additions and 3 deletions
|
@ -242,7 +242,11 @@ exit:
|
|||
PyDoc_STRVAR(_io__IOBase_writelines__doc__,
|
||||
"writelines($self, lines, /)\n"
|
||||
"--\n"
|
||||
"\n");
|
||||
"\n"
|
||||
"Write a list of lines to stream.\n"
|
||||
"\n"
|
||||
"Line separators are not added, so it is usual for each of the\n"
|
||||
"lines provided to have a line separator at the end.");
|
||||
|
||||
#define _IO__IOBASE_WRITELINES_METHODDEF \
|
||||
{"writelines", (PyCFunction)_io__IOBase_writelines, METH_O, _io__IOBase_writelines__doc__},
|
||||
|
@ -311,4 +315,4 @@ _io__RawIOBase_readall(PyObject *self, PyObject *Py_UNUSED(ignored))
|
|||
{
|
||||
return _io__RawIOBase_readall_impl(self);
|
||||
}
|
||||
/*[clinic end generated code: output=60e43a7cbd9f314e input=a9049054013a1b77]*/
|
||||
/*[clinic end generated code: output=61b6ea7153ef9940 input=a9049054013a1b77]*/
|
||||
|
|
|
@ -751,11 +751,16 @@ _io__IOBase_readlines_impl(PyObject *self, Py_ssize_t hint)
|
|||
_io._IOBase.writelines
|
||||
lines: object
|
||||
/
|
||||
|
||||
Write a list of lines to stream.
|
||||
|
||||
Line separators are not added, so it is usual for each of the
|
||||
lines provided to have a line separator at the end.
|
||||
[clinic start generated code]*/
|
||||
|
||||
static PyObject *
|
||||
_io__IOBase_writelines(PyObject *self, PyObject *lines)
|
||||
/*[clinic end generated code: output=976eb0a9b60a6628 input=432e729a8450b3cb]*/
|
||||
/*[clinic end generated code: output=976eb0a9b60a6628 input=cac3fc8864183359]*/
|
||||
{
|
||||
PyObject *iter, *res;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue