Introduce importlib.util.ModuleManager which is a context manager to

handle providing (and cleaning up if needed) the module to be loaded.

A future commit will use the context manager in
Lib/importlib/_bootstrap.py and thus why the code is placed there
instead of in Lib/importlib/util.py.
This commit is contained in:
Brett Cannon 2013-05-28 17:29:34 -04:00
parent 4dbae88131
commit a3687f0d68
6 changed files with 3508 additions and 3341 deletions

View file

@ -1,5 +1,6 @@
"""Utility code for constructing importers, etc."""
from ._bootstrap import ModuleManager
from ._bootstrap import module_for_loader
from ._bootstrap import set_loader
from ._bootstrap import set_package