You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 16:59:52 +08:00
Python 2.6 grammary bug and..
__pkginfo.py__: Bump spark_parser version for parse_flags 'dups'
This commit is contained in:
@@ -37,7 +37,7 @@ entry_points={
|
|||||||
'pydisassemble=uncompyle6.bin.pydisassemble:main',
|
'pydisassemble=uncompyle6.bin.pydisassemble:main',
|
||||||
]}
|
]}
|
||||||
ftp_url = None
|
ftp_url = None
|
||||||
install_requires = ['spark-parser >= 1.4.0, < 1.5.0',
|
install_requires = ['spark-parser >= 1.4.3, < 1.5.0',
|
||||||
'xdis >= 3.2.3, < 3.3.0']
|
'xdis >= 3.2.3, < 3.3.0']
|
||||||
license = 'MIT'
|
license = 'MIT'
|
||||||
mailing_list = 'python-debugger@googlegroups.com'
|
mailing_list = 'python-debugger@googlegroups.com'
|
||||||
|
@@ -59,5 +59,5 @@ def test_dup_rule():
|
|||||||
python_parser(PYTHON_VERSION, inspect.currentframe().f_code,
|
python_parser(PYTHON_VERSION, inspect.currentframe().f_code,
|
||||||
is_pypy=IS_PYPY,
|
is_pypy=IS_PYPY,
|
||||||
parser_debug={
|
parser_debug={
|
||||||
'rules': True, 'transition': False, 'reduce': False,
|
'dups': True, 'transition': False, 'reduce': False,
|
||||||
'errorstack': None, 'context': True})
|
'rules': False, 'errorstack': None, 'context': True})
|
||||||
|
@@ -709,8 +709,8 @@ def python_parser(version, co, out=sys.stdout, showasm=False,
|
|||||||
maybe_show_asm(showasm, tokens)
|
maybe_show_asm(showasm, tokens)
|
||||||
|
|
||||||
# For heavy grammar debugging
|
# For heavy grammar debugging
|
||||||
parser_debug = {'rules': True, 'transition': True, 'reduce' : True,
|
# parser_debug = {'rules': True, 'transition': True, 'reduce' : True,
|
||||||
'showstack': 'full'}
|
# 'showstack': 'full'}
|
||||||
p = get_python_parser(version, parser_debug)
|
p = get_python_parser(version, parser_debug)
|
||||||
return parse(p, tokens, customize)
|
return parse(p, tokens, customize)
|
||||||
|
|
||||||
|
@@ -84,6 +84,7 @@ class Python26Parser(Python2Parser):
|
|||||||
jb_cont ::= CONTINUE
|
jb_cont ::= CONTINUE
|
||||||
|
|
||||||
jb_cf_pop ::= JUMP_BACK come_froms POP_TOP
|
jb_cf_pop ::= JUMP_BACK come_froms POP_TOP
|
||||||
|
jb_cf_pop ::= JUMP_BACK POP_TOP
|
||||||
ja_cf_pop ::= JUMP_ABSOLUTE come_froms POP_TOP
|
ja_cf_pop ::= JUMP_ABSOLUTE come_froms POP_TOP
|
||||||
jf_cf_pop ::= JUMP_FORWARD come_froms POP_TOP
|
jf_cf_pop ::= JUMP_FORWARD come_froms POP_TOP
|
||||||
|
|
||||||
@@ -188,6 +189,8 @@ class Python26Parser(Python2Parser):
|
|||||||
|
|
||||||
comp_body ::= gen_comp_body
|
comp_body ::= gen_comp_body
|
||||||
|
|
||||||
|
for_block ::= l_stmts_opt _come_from POP_TOP JUMP_BACK
|
||||||
|
|
||||||
# Make sure we keep indices the same as 2.7
|
# Make sure we keep indices the same as 2.7
|
||||||
setup_loop_lf ::= SETUP_LOOP LOAD_FAST
|
setup_loop_lf ::= SETUP_LOOP LOAD_FAST
|
||||||
genexpr_func ::= setup_loop_lf FOR_ITER designator comp_iter jb_bp_come_from
|
genexpr_func ::= setup_loop_lf FOR_ITER designator comp_iter jb_bp_come_from
|
||||||
|
Reference in New Issue
Block a user