[pypy-commit] pypy exc-later: fix rpython/translator/c/test/test_exception.py::test_getitem_custom_exception

rlamy noreply at buildbot.pypy.org
Mon Mar 23 04:16:01 CET 2015


Author: Ronan Lamy <ronan.lamy at gmail.com>
Branch: exc-later
Changeset: r76507:ecfb2b754b12
Date: 2015-03-23 03:13 +0000
http://bitbucket.org/pypy/pypy/changeset/ecfb2b754b12/

Log:	fix rpython/translator/c/test/test_exception.py::test_getitem_custom
	_exception

diff --git a/rpython/translator/simplify.py b/rpython/translator/simplify.py
--- a/rpython/translator/simplify.py
+++ b/rpython/translator/simplify.py
@@ -342,7 +342,7 @@
                 if not exits:
                     block.exitswitch = None
                 block.recloseblock(block.exits[0], *exits)
-            else:
+            if Exception in op.canraise:
                 if block.exits[-1].exitcase is not Exception:
                     v_etype = Variable('last_exception')
                     v_exc = Variable('last_exc_value')


More information about the pypy-commit mailing list