You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-02 16:44:46 +08:00
14 lines
320 B
Python
14 lines
320 B
Python
# From 3.6.4 pathlib.py
|
|
# Bug was handling "continue" as last statement of "if"
|
|
# RUNNABLE!
|
|
def parse_parts(it, parts):
|
|
for part in it:
|
|
if not part:
|
|
continue
|
|
parts = 1
|
|
return parts
|
|
|
|
assert parse_parts([], 5) == 5
|
|
assert parse_parts([True], 6) == 1
|
|
assert parse_parts([False], 6) == 6
|