[Python-checkins] cpython (3.3): [issue19151] Fix docstring and use of _get_suppported_file_loaders() to reflect

eric.snow python-checkins at python.org
Thu Oct 3 21:53:20 CEST 2013


http://hg.python.org/cpython/rev/32b18998a560
changeset:   85945:32b18998a560
branch:      3.3
parent:      85939:b08e092df155
user:        Eric Snow <ericsnowcurrently at gmail.com>
date:        Thu Oct 03 12:08:55 2013 -0600
summary:
  [issue19151] Fix docstring and use of _get_suppported_file_loaders() to reflect 2-tuples.

files:
  Lib/importlib/_bootstrap.py |     4 +-
  Misc/NEWS                   |     3 +
  Python/importlib.h          |  5262 +++++++++++-----------
  3 files changed, 2635 insertions(+), 2634 deletions(-)


diff --git a/Lib/importlib/_bootstrap.py b/Lib/importlib/_bootstrap.py
--- a/Lib/importlib/_bootstrap.py
+++ b/Lib/importlib/_bootstrap.py
@@ -781,7 +781,7 @@
             _os.stat(filepath)
         except OSError:
             return None
-        for loader, suffixes, _ in _get_supported_file_loaders():
+        for loader, suffixes in _get_supported_file_loaders():
             if filepath.endswith(tuple(suffixes)):
                 return loader(fullname, filepath)
 
@@ -1643,7 +1643,7 @@
 def _get_supported_file_loaders():
     """Returns a list of file-based module loaders.
 
-    Each item is a tuple (loader, suffixes, allow_packages).
+    Each item is a tuple (loader, suffixes).
     """
     extensions = ExtensionFileLoader, _imp.extension_suffixes()
     source = SourceFileLoader, SOURCE_SUFFIXES
diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -203,6 +203,9 @@
 
 - Issue #18405: Improve the entropy of crypt.mksalt().
 
+- Issue #19151: Fix docstring and use of _get_suppported_file_loaders() to
+  reflect 2-tuples.
+
 - Issue #18676: Change 'positive' to 'non-negative' in queue.py put and get
   docstrings and ValueError messages. Patch by Zhongyue Luo
 
diff --git a/Python/importlib.h b/Python/importlib.h
--- a/Python/importlib.h
+++ b/Python/importlib.h
[stripped]

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


More information about the Python-checkins mailing list