Test case for #284

This commit is contained in:
Grigory Trenin
2019-08-12 02:09:51 +03:00
parent 388d1da970
commit 31f7d14eab
2 changed files with 19 additions and 0 deletions

Binary file not shown.

View File

@@ -0,0 +1,19 @@
# Issue #284 in Python 2.6
# See https://github.com/rocky/python-uncompyle6/issues/284
# Decompilation failed when return was the last statetement
# in the while loop inside the if block
# This code is RUNNABLE!
def f1():
if True:
while True:
return 5
def f2():
if True:
while 1:
return 6
assert f1() == 5 and f2() == 6