From: Antoine Pitrou Date: Tue, 11 Oct 2011 14:07:30 +0000 (+0200) Subject: Use a dict for faster sysconfig startup (issue #13150) X-Git-Tag: v3.3.0a1~1230 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=dc567e42f7f3c22bce09275611dfc1a4a1f7ebde;p=thirdparty%2FPython%2Fcpython.git Use a dict for faster sysconfig startup (issue #13150) --- diff --git a/Lib/sysconfig.py b/Lib/sysconfig.py index d07784d9670c..6594104e0652 100644 --- a/Lib/sysconfig.py +++ b/Lib/sysconfig.py @@ -24,7 +24,7 @@ __all__ = [ # XXX _CONFIG_DIR will be set by the Makefile later _CONFIG_DIR = os.path.normpath(os.path.dirname(__file__)) _CONFIG_FILE = os.path.join(_CONFIG_DIR, 'sysconfig.cfg') -_SCHEMES = RawConfigParser() +_SCHEMES = RawConfigParser(dict_type=dict) # Faster than OrderedDict _SCHEMES.read(_CONFIG_FILE) _VAR_REPL = re.compile(r'\{([^{]*?)\}')