[Python-checkins] cpython (3.4): Issue #24713: Use importlib.reload() in import reference document.

berker.peksag python-checkins at python.org
Sat Jul 25 12:03:55 CEST 2015


https://hg.python.org/cpython/rev/6c713dcce26a
changeset:   97055:6c713dcce26a
branch:      3.4
parent:      97049:fc1d40a706e7
user:        Berker Peksag <berker.peksag at gmail.com>
date:        Sat Jul 25 13:02:37 2015 +0300
summary:
  Issue #24713: Use importlib.reload() in import reference document.

imp.reload() was deprecated in Python 3.4 and changed to call
importlib.reload().

Patch by Petr Viktorin.

files:
  Doc/reference/import.rst |  2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)


diff --git a/Doc/reference/import.rst b/Doc/reference/import.rst
--- a/Doc/reference/import.rst
+++ b/Doc/reference/import.rst
@@ -200,7 +200,7 @@
 Beware though, as if you keep a reference to the module object,
 invalidate its cache entry in :data:`sys.modules`, and then re-import the
 named module, the two module objects will *not* be the same. By contrast,
-:func:`imp.reload` will reuse the *same* module object, and simply
+:func:`importlib.reload` will reuse the *same* module object, and simply
 reinitialise the module contents by rerunning the module's code.
 
 

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list