[pypy-commit] pypy virtual-dicts: make this consistant with the other version of this code

alex_gaynor noreply at buildbot.pypy.org
Wed Oct 26 21:15:39 CEST 2011


Author: Alex Gaynor <alex.gaynor at gmail.com>
Branch: virtual-dicts
Changeset: r48485:072b6ee49f10
Date: 2011-10-26 15:15 -0400
http://bitbucket.org/pypy/pypy/changeset/072b6ee49f10/

Log:	make this consistant with the other version of this code

diff --git a/pypy/jit/metainterp/optimizeopt/virtualize.py b/pypy/jit/metainterp/optimizeopt/virtualize.py
--- a/pypy/jit/metainterp/optimizeopt/virtualize.py
+++ b/pypy/jit/metainterp/optimizeopt/virtualize.py
@@ -504,8 +504,10 @@
             if indexbox is not None:
                 descr = op.getdescr()
                 fieldvalue = value.getinteriorfield(
-                    indexbox.getint(), descr, self.new_const(descr)
+                    indexbox.getint(), descr, None
                 )
+                if fieldvalue is None:
+                    fieldvalue = self.new_const(descr)
                 self.make_equal_to(op.result, fieldvalue)
                 return
         value.ensure_nonnull()


More information about the pypy-commit mailing list