[pypy-svn] r15250 - in pypy/branch/pypy-newobjspace: objspace/std translator/goal

hpk at codespeak.net hpk at codespeak.net
Thu Jul 28 16:09:10 CEST 2005


Author: hpk
Date: Thu Jul 28 16:09:08 2005
New Revision: 15250

Modified:
   pypy/branch/pypy-newobjspace/objspace/std/objspace.py
   pypy/branch/pypy-newobjspace/translator/goal/targetpypymain.py
Log:
- adapt object space initialization from translation 
- small renaming


Modified: pypy/branch/pypy-newobjspace/objspace/std/objspace.py
==============================================================================
--- pypy/branch/pypy-newobjspace/objspace/std/objspace.py	(original)
+++ pypy/branch/pypy-newobjspace/objspace/std/objspace.py	Thu Jul 28 16:09:08 2005
@@ -103,7 +103,7 @@
         """) 
 
         if self.options.uselibfile:
-            self.setuselibfile() 
+            self.inituselibfile() 
 
     def enable_old_style_classes_as_default_metaclass(self):
         self.setitem(self.builtin.w_dict, self.wrap('__metaclass__'), self.w_classobj)
@@ -151,7 +151,7 @@
         w_mod = self.wrap(mod)
         return w_mod, w_dic
 
-    def setuselibfile(self): 
+    def inituselibfile(self): 
         """ NOT_RPYTHON use our application level file implementation
             including re-wrapping sys.stdout/err/in
         """ 
@@ -159,7 +159,7 @@
         space = self
         # nice print helper if the below does not work 
         # (we dont have prints working at applevel before
-        # setuselibfile is complete)
+        # inituselibfile is complete)
         #from pypy.interpreter import gateway 
         #def printit(space, w_msg): 
         #    s = space.str_w(w_msg) 

Modified: pypy/branch/pypy-newobjspace/translator/goal/targetpypymain.py
==============================================================================
--- pypy/branch/pypy-newobjspace/translator/goal/targetpypymain.py	(original)
+++ pypy/branch/pypy-newobjspace/translator/goal/targetpypymain.py	Thu Jul 28 16:09:08 2005
@@ -38,11 +38,7 @@
     # XXX why can't I enable this? crashes the annotator!
     gateway.ApplevelClass.use_geninterp = False
 
-    from pypy.tool.option import Options
-    options = Options()
-    options.uselibfile = True
-    options.nofakedmodules = True
-    space = StdObjSpace(options)
+    space = StdObjSpace(nofaking=True) 
 
     # manually imports app_main.py
     filename = os.path.join(this_dir, 'app_main.py')



More information about the Pypy-commit mailing list