summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2014-06-15 01:51:34 (GMT)
committerBenjamin Peterson <benjamin@python.org>2014-06-15 01:51:34 (GMT)
commitef8abfc082daeb6e389dff8859640ed87da0cc12 (patch)
tree580476591d56dd7bc0159fa981aab3e9d6e15d85 /Doc
parenta8c75fe31ae81231b05a4e100529f8d70ea93ef2 (diff)
downloadcpython-ef8abfc082daeb6e389dff8859640ed87da0cc12.zip
cpython-ef8abfc082daeb6e389dff8859640ed87da0cc12.tar.gz
cpython-ef8abfc082daeb6e389dff8859640ed87da0cc12.tar.bz2
document IOBase.__del__'s behavior (closes #21764)
Patch from Nikolaus Rath.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/io.rst6
1 files changed, 6 insertions, 0 deletions
diff --git a/Doc/library/io.rst b/Doc/library/io.rst
index 79f65e0..0c7d3c7 100644
--- a/Doc/library/io.rst
+++ b/Doc/library/io.rst
@@ -353,6 +353,12 @@ I/O Base Classes
is usual for each of the lines provided to have a line separator at the
end.
+ .. method:: __del__()
+
+ Prepare for object destruction. :class:`IOBase` provides a default
+ implementation of this method that calls the instance's
+ :meth:`~IOBase.close` method.
+
.. class:: RawIOBase