[pypy-commit] lang-smalltalk default: (krono, timfel) fix closure detection when creating a MethodContext shadow

timfel noreply at buildbot.pypy.org
Fri Apr 19 16:53:47 CEST 2013


Author: Tim Felgentreff <timfelgentreff at gmail.com>
Branch: 
Changeset: r301:aa6a44388258
Date: 2013-04-19 16:51 +0200
http://bitbucket.org/pypy/lang-smalltalk/changeset/aa6a44388258/

Log:	(krono, timfel) fix closure detection when creating a MethodContext
	shadow

diff --git a/spyvm/shadow.py b/spyvm/shadow.py
--- a/spyvm/shadow.py
+++ b/spyvm/shadow.py
@@ -873,8 +873,10 @@
     
     @jit.dont_look_inside
     def attach_shadow(self):
-        # Make sure the method is updated first
+        # Make sure the method and closure_or_nil are updated first,
+        # otherwise tempsize may be wrong
         self.copy_from_w_self(constants.MTHDCTX_METHOD)
+        self.copy_from_w_self(constants.MTHDCTX_CLOSURE_OR_NIL)
         self.init_stack_and_temps()
         ContextPartShadow.attach_shadow(self)
 


More information about the pypy-commit mailing list