Author: Armin Rigo <ar...@tunes.org> Branch: Changeset: r48191:8ba326c260b0 Date: 2011-10-18 12:05 +0200 http://bitbucket.org/pypy/pypy/changeset/8ba326c260b0/
Log: Uh, this seems to fix pypy.objspace.test.test_binop_overriding. I will try to write a unit test and comments for it. diff --git a/pypy/jit/metainterp/quasiimmut.py b/pypy/jit/metainterp/quasiimmut.py --- a/pypy/jit/metainterp/quasiimmut.py +++ b/pypy/jit/metainterp/quasiimmut.py @@ -74,12 +74,8 @@ self.looptokens_wrefs.append(wref_looptoken) def compress_looptokens_list(self): - newlist = [] - for wref in self.looptokens_wrefs: - looptoken = wref() - if looptoken is not None and not looptoken.invalidated: - newlist.append(wref) - self.looptokens_wrefs = newlist + self.looptokens_wref = [wref for wref in self.looptokens_wrefs + if wref() is not None] self.compress_limit = (len(self.looptokens_wrefs) + 15) * 2 def invalidate(self): @@ -90,7 +86,7 @@ self.looptokens_wrefs = [] for wref in wrefs: looptoken = wref() - if looptoken is not None and not looptoken.invalidated: + if looptoken is not None: looptoken.invalidated = True self.cpu.invalidate_loop(looptoken) if not we_are_translated(): _______________________________________________ pypy-commit mailing list pypy-commit@python.org http://mail.python.org/mailman/listinfo/pypy-commit