summaryrefslogtreecommitdiffstats
path: root/Doc/reference/simple_stmts.rst
diff options
context:
space:
mode:
authorBrett Cannon <bcannon@gmail.com>2009-08-30 04:00:12 (GMT)
committerBrett Cannon <bcannon@gmail.com>2009-08-30 04:00:12 (GMT)
commit757df6e4cd0578ed86db188a2331a4e83764c42c (patch)
treeda38ac18ff70e31b20f5516e8bab29ec99a2a1cd /Doc/reference/simple_stmts.rst
parent4d75fc1ce97bd15126442c16faab8931aaa7ade2 (diff)
downloadcpython-757df6e4cd0578ed86db188a2331a4e83764c42c.zip
cpython-757df6e4cd0578ed86db188a2331a4e83764c42c.tar.gz
cpython-757df6e4cd0578ed86db188a2331a4e83764c42c.tar.bz2
Document the import semantics that if None is found in sys.modules for a module then ImportError is raised.
Diffstat (limited to 'Doc/reference/simple_stmts.rst')
-rw-r--r--Doc/reference/simple_stmts.rst4
1 files changed, 3 insertions, 1 deletions
diff --git a/Doc/reference/simple_stmts.rst b/Doc/reference/simple_stmts.rst
index 2a34b69..7387da7 100644
--- a/Doc/reference/simple_stmts.rst
+++ b/Doc/reference/simple_stmts.rst
@@ -668,7 +668,9 @@ Once the name of the module is known (unless otherwise specified, the term
"module" will refer to both packages and modules), searching
for the module or package can begin. The first place checked is
:data:`sys.modules`, the cache of all modules that have been imported
-previously. If the module is found there then it is used in step (2) of import.
+previously. If the module is found there then it is used in step (2) of import
+unless :keyword:`None` is found in :data:`sys.modules`, in which case
+:exc:`ImportError` is raised.
.. index::
single: sys.meta_path