]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-85045: clarified that the underlying buffer of a TextIOBase can be a RawIOBase...
authorAlex Kautz <alex@takemobi.com>
Tue, 20 May 2025 18:18:58 +0000 (14:18 -0400)
committerGitHub <noreply@github.com>
Tue, 20 May 2025 18:18:58 +0000 (18:18 +0000)
Added a clarification that the underlying binary buffer of a TextIOBase can be a BufferedIOBase OR a RawIOBase

Doc/library/io.rst

index 3aa2f35f05eba0d598874fe8dc0b9944becb4043..08c76da3d8c00a4ee9e631d9df5145a4d0b75854 100644 (file)
@@ -894,9 +894,10 @@ Text I/O
 
    .. attribute:: buffer
 
-      The underlying binary buffer (a :class:`BufferedIOBase` instance) that
-      :class:`TextIOBase` deals with.  This is not part of the
-      :class:`TextIOBase` API and may not exist in some implementations.
+      The underlying binary buffer (a :class:`BufferedIOBase`
+      or :class:`RawIOBase` instance) that :class:`TextIOBase` deals with.
+      This is not part of the :class:`TextIOBase` API and may not exist
+      in some implementations.
 
    .. method:: detach()