You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 08:49:51 +08:00
Start Python3 execption handling
This commit is contained in:
@@ -4,4 +4,9 @@ across all versions of Python.
|
||||
Their simnplicity is to try to make it easier to debug grammar
|
||||
and AST walking routines.
|
||||
|
||||
This code originally taken from https://github.com/DarkFenX/uncompyle3
|
||||
The numbers in the filenames are to assist running the programs from
|
||||
the simplest to more complex. For example, many tests have assignment
|
||||
statements or function calls, so we want to test those constructs
|
||||
first.
|
||||
|
||||
Code and organization merged from uncompyle3, uncompyle{,2}, and pycdc
|
||||
|
@@ -1,4 +1,27 @@
|
||||
# Tests:
|
||||
# trystmt ::= SETUP_EXCEPT suite_stmts_opt POP_BLOCK
|
||||
# try_middle COME_FROM
|
||||
# except_stmt ::= except
|
||||
|
||||
try:
|
||||
x = 1
|
||||
except:
|
||||
pass
|
||||
|
||||
# Tests:
|
||||
# trystmt ::= SETUP_EXCEPT suite_stmts_opt POP_BLOCK
|
||||
# try_middle COME_FROM
|
||||
# except_stmt ::= except_cond1 except_suite
|
||||
# except_suite ::= ...
|
||||
|
||||
try:
|
||||
x = 1
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
try:
|
||||
x = 2
|
||||
except ImportError:
|
||||
x = 3
|
||||
finally:
|
||||
x = 4
|
||||
|
@@ -1 +0,0 @@
|
||||
vario = 'None'
|
@@ -1,4 +1,6 @@
|
||||
# Tests:
|
||||
# assign ::= expr designator
|
||||
|
||||
vario = 556
|
||||
a = 'None'
|
||||
b = None
|
||||
c = 556
|
Reference in New Issue
Block a user