summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorBrett Cannon <bcannon@gmail.com>2009-01-29 00:54:11 (GMT)
committerBrett Cannon <bcannon@gmail.com>2009-01-29 00:54:11 (GMT)
commit5b0d5531f2b688dfff2eaac529a9bb57c4ee839d (patch)
tree844555acaf1e77f2412162c155d02f6328521241 /Doc
parent1712baa852956cce1c44649f9178956146366fa7 (diff)
downloadcpython-5b0d5531f2b688dfff2eaac529a9bb57c4ee839d.zip
cpython-5b0d5531f2b688dfff2eaac529a9bb57c4ee839d.tar.gz
cpython-5b0d5531f2b688dfff2eaac529a9bb57c4ee839d.tar.bz2
Clarify some __del__ stuff.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/reference/datamodel.rst4
1 files changed, 3 insertions, 1 deletions
diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst
index dbcc9a1..5b6f1e8 100644
--- a/Doc/reference/datamodel.rst
+++ b/Doc/reference/datamodel.rst
@@ -1257,7 +1257,9 @@ Basic customization
is printed to ``sys.stderr`` instead. Also, when :meth:`__del__` is invoked in
response to a module being deleted (e.g., when execution of the program is
done), other globals referenced by the :meth:`__del__` method may already have
- been deleted. For this reason, :meth:`__del__` methods should do the absolute
+ been deleted or in the process of being torn down (e.g. the import
+ machinery shutting down). For this reason, :meth:`__del__` methods
+ should do the absolute
minimum needed to maintain external invariants. Starting with version 1.5,
Python guarantees that globals whose name begins with a single underscore are
deleted from their module before other globals are deleted; if no other