[pypy-svn] pypy mixed-submodules: Use the new Module.install for the modules which get special treatment.
alex_gaynor
commits-noreply at bitbucket.org
Thu Dec 30 23:24:11 CET 2010
Author: Alex Gaynor <alex.gaynor at gmail.com>
Branch: mixed-submodules
Changeset: r40300:0b58c3c2a32e
Date: 2010-12-30 16:23 -0600
http://bitbucket.org/pypy/pypy/changeset/0b58c3c2a32e/
Log: Use the new Module.install for the modules which get special
treatment.
diff --git a/pypy/interpreter/baseobjspace.py b/pypy/interpreter/baseobjspace.py
--- a/pypy/interpreter/baseobjspace.py
+++ b/pypy/interpreter/baseobjspace.py
@@ -456,22 +456,23 @@
from pypy.module.exceptions import Module
w_name = self.wrap('exceptions')
self.exceptions_module = Module(self, w_name)
- self.builtin_modules['exceptions'] = self.wrap(self.exceptions_module)
+ self.exceptions_module.install()
from pypy.module.sys import Module
w_name = self.wrap('sys')
self.sys = Module(self, w_name)
- self.builtin_modules['sys'] = self.wrap(self.sys)
+ self.sys.install()
from pypy.module.imp import Module
w_name = self.wrap('imp')
- self.builtin_modules['imp'] = self.wrap(Module(self, w_name))
+ mod = Module(self, w_name)
+ mod.install()
from pypy.module.__builtin__ import Module
w_name = self.wrap('__builtin__')
self.builtin = Module(self, w_name)
w_builtin = self.wrap(self.builtin)
- self.builtin_modules['__builtin__'] = self.wrap(w_builtin)
+ self.builtin.install()
self.setitem(self.builtin.w_dict, self.wrap('__builtins__'), w_builtin)
bootstrap_modules = set(('sys', 'imp', '__builtin__', 'exceptions'))
More information about the Pypy-commit
mailing list