Author: Lars Wassermann <[email protected]>
Branch: 
Changeset: r390:f71c099e545b
Date: 2013-05-15 14:06 +0200
http://bitbucket.org/pypy/lang-smalltalk/changeset/f71c099e545b/

Log:    fixed translation error in ContextPartShadow>>#print_stack

diff --git a/spyvm/shadow.py b/spyvm/shadow.py
--- a/spyvm/shadow.py
+++ b/spyvm/shadow.py
@@ -709,16 +709,17 @@
     # Debugging printout
 
     def print_stack(self, method=True):
-        def print_padded_stack(s_context, method):
-            padding = ret_str = ''
-            if s_context.s_sender() is not None:
-                    padding, ret_str = 
print_padded_stack(s_context.s_sender(), method)
-            if method:
-                desc = s_context.method_str()
-            else:
-                desc = s_context.short_str(0)
-            return padding + ' ', '%s\n%s%s' % (ret_str, padding, desc)
-        return print_padded_stack(self, method)[1]
+        return self.print_padded_stack(method)[1]
+
+    def print_padded_stack(self, method):
+        padding = ret_str = ''
+        if self.s_sender() is not None:
+                padding, ret_str = self.s_sender().print_padded_stack(method)
+        if method:
+            desc = self.method_str()
+        else:
+            desc = self.short_str(0)
+        return padding + ' ', '%s\n%s%s' % (ret_str, padding, desc)
 
 
 class BlockContextShadow(ContextPartShadow):
diff --git a/spyvm/test/test_bootstrappedimage.py 
b/spyvm/test/test_bootstrappedimage.py
--- a/spyvm/test/test_bootstrappedimage.py
+++ b/spyvm/test/test_bootstrappedimage.py
@@ -6,6 +6,7 @@
 
 def setup():
     tools.setup_module(tools, filename='bootstrapped.image')
+    test_initialize_string_class()
 
 def find_symbol_in_methoddict_of(string, s_class):
     s_methoddict = s_class.s_methoddict()
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to