[pypy-svn] r63720 - pypy/branch/pyjitpl5-simplify/pypy/jit/metainterp
arigo at codespeak.net
arigo at codespeak.net
Mon Apr 6 15:14:15 CEST 2009
Author: arigo
Date: Mon Apr 6 15:14:13 2009
New Revision: 63720
Modified:
pypy/branch/pyjitpl5-simplify/pypy/jit/metainterp/history.py
Log:
Add _attrs_ on the box classes, to prevent unwanted attributes
from showing up during translation.
Modified: pypy/branch/pyjitpl5-simplify/pypy/jit/metainterp/history.py
==============================================================================
--- pypy/branch/pyjitpl5-simplify/pypy/jit/metainterp/history.py (original)
+++ pypy/branch/pyjitpl5-simplify/pypy/jit/metainterp/history.py Mon Apr 6 15:14:13 2009
@@ -146,6 +146,7 @@
class ConstInt(Const):
type = INT
+ _attrs_ = ('value',)
def __init__(self, value):
if not we_are_translated():
@@ -182,6 +183,7 @@
class ConstAddr(Const): # only for constants built before translation
type = INT
+ _attrs_ = ('value', 'cpu')
def __init__(self, adrvalue, cpu):
"NOT_RPYTHON"
@@ -216,6 +218,7 @@
class ConstPtr(Const):
type = PTR
value = lltype.nullptr(llmemory.GCREF.TO)
+ _attrs_ = ('value',)
def __init__(self, value):
assert lltype.typeOf(value) == llmemory.GCREF
@@ -282,6 +285,7 @@
class BoxInt(Box):
type = INT
+ _attrs_ = ('value',)
def __init__(self, value=0):
if not we_are_translated():
@@ -310,6 +314,7 @@
class BoxPtr(Box):
type = PTR
+ _attrs_ = ('value',)
def __init__(self, value=lltype.nullptr(llmemory.GCREF.TO)):
assert lltype.typeOf(value) == llmemory.GCREF
More information about the Pypy-commit
mailing list