]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-59254: mention in open() doc that line buffering is for writing (#112318)
authorIrit Katriel <1055913+iritkatriel@users.noreply.github.com>
Fri, 24 Nov 2023 17:59:41 +0000 (17:59 +0000)
committerGitHub <noreply@github.com>
Fri, 24 Nov 2023 17:59:41 +0000 (18:59 +0100)
Doc/library/functions.rst

index a72f779f69714a7914bf123bca734c79cf48f03a..b2dd32f925ef4df1bd1862e7d4903faf43c3992c 100644 (file)
@@ -1221,7 +1221,7 @@ are always available.  They are listed here in alphabetical order.
 
    *buffering* is an optional integer used to set the buffering policy.  Pass 0
    to switch buffering off (only allowed in binary mode), 1 to select line
-   buffering (only usable in text mode), and an integer > 1 to indicate the size
+   buffering (only usable when writing in text mode), and an integer > 1 to indicate the size
    in bytes of a fixed-size chunk buffer. Note that specifying a buffer size this
    way applies for binary buffered I/O, but ``TextIOWrapper`` (i.e., files opened
    with ``mode='r+'``) would have another buffering. To disable buffering in