[pypy-svn] r5046 - pypy/trunk/src/pypy/interpreter
mwh at codespeak.net
mwh at codespeak.net
Fri Jun 11 13:01:21 CEST 2004
Author: mwh
Date: Fri Jun 11 13:01:20 2004
New Revision: 5046
Modified:
pypy/trunk/src/pypy/interpreter/nestedscope.py
pypy/trunk/src/pypy/interpreter/typedef.py
Log:
make Cell Wrappable
Modified: pypy/trunk/src/pypy/interpreter/nestedscope.py
==============================================================================
--- pypy/trunk/src/pypy/interpreter/nestedscope.py (original)
+++ pypy/trunk/src/pypy/interpreter/nestedscope.py Fri Jun 11 13:01:20 2004
@@ -2,9 +2,9 @@
from pypy.interpreter.eval import UNDEFINED
from pypy.interpreter.pyopcode import PyInterpFrame
from pypy.interpreter import function, pycode
+from pypy.interpreter.baseobjspace import Wrappable
-
-class Cell(object):
+class Cell(Wrappable):
"A simple container for a wrapped value."
def __init__(self, w_value=UNDEFINED):
Modified: pypy/trunk/src/pypy/interpreter/typedef.py
==============================================================================
--- pypy/trunk/src/pypy/interpreter/typedef.py (original)
+++ pypy/trunk/src/pypy/interpreter/typedef.py Fri Jun 11 13:01:20 2004
@@ -83,6 +83,7 @@
from pypy.interpreter.function import Function, Method, StaticMethod
from pypy.interpreter.pytraceback import PyTraceback
from pypy.interpreter.generator import GeneratorIterator
+from pypy.interpreter.nestedscope import Cell
Code.typedef = TypeDef('internal-code',
co_name = attrproperty('co_name'),
@@ -166,3 +167,5 @@
gi_running = attrproperty('running'),
gi_frame = attrproperty('frame'),
)
+
+Cell.typedef = TypeDef("Cell")
More information about the Pypy-commit
mailing list