[pypy-svn] rev 815 - pypy/trunk/src/pypy/objspace

mwh at codespeak.net mwh at codespeak.net
Mon Jun 16 20:05:25 CEST 2003


Author: mwh
Date: Mon Jun 16 20:05:25 2003
New Revision: 815

Modified:
   pypy/trunk/src/pypy/objspace/trivial.py
Log:
tweaks, to allow running dis-pregoal under the trivial object space.


Modified: pypy/trunk/src/pypy/objspace/trivial.py
==============================================================================
--- pypy/trunk/src/pypy/objspace/trivial.py	(original)
+++ pypy/trunk/src/pypy/objspace/trivial.py	Mon Jun 16 20:05:25 2003
@@ -66,10 +66,17 @@
         self.w_None = None
         self.w_True = True
         self.w_False = False
+        self.w_NotImplemented = NotImplemented
+        self.w_Ellipsis = Ellipsis
         import __builtin__, types
         newstuff = {"False": self.w_False,
                     "True" : self.w_True,
+                    "NotImplemented" : self.w_NotImplemented,
                     "None" : self.w_None,
+                    "Ellipsis" : self.w_Ellipsis,
+                    "buffer": buffer,
+                    "xrange": xrange,
+                    "slice": slice,
                     }
         for n, c in __builtin__.__dict__.iteritems():
             if isinstance(c, types.TypeType):
@@ -255,7 +262,7 @@
             def __init__(self, space, code, globals, defaultarguments, closure):
                 self.space = space
                 self.__name__ = code.co_name
-                self.code = code
+                self.func_code = self.code = code
                 self.globals = globals
                 self.defaultarguments = defaultarguments
                 self.closure = closure


More information about the Pypy-commit mailing list