You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-02 16:44:46 +08:00
Add tests, comment what's up with change..
and use isinstance()
This commit is contained in:
18
test/simple_source/bug24/02_loop_continue_dead_code.py
Normal file
18
test/simple_source/bug24/02_loop_continue_dead_code.py
Normal file
@@ -0,0 +1,18 @@
|
||||
"""This program is self-checking!"""
|
||||
# Python 2.4 - 2.7 bug in transforming "else if" to "elif" in Python 2.4 .. 2.7
|
||||
# From Issue #377
|
||||
|
||||
# RUNNABLE!
|
||||
def loop_continue_dead_code(slots):
|
||||
for name in slots:
|
||||
if name:
|
||||
pass
|
||||
else:
|
||||
continue
|
||||
# The below is dead code
|
||||
if x:
|
||||
y()
|
||||
else:
|
||||
z()
|
||||
|
||||
loop_continue_dead_code([None, 1])
|
Reference in New Issue
Block a user