You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-04 09:22:40 +08:00
Fix subscript in store_annotation + indentation
This commit is contained in:
@@ -276,6 +276,7 @@ class Python36Parser(Python35Parser):
|
|||||||
ann_assign_init_value ::= expr store store_annotation
|
ann_assign_init_value ::= expr store store_annotation
|
||||||
ann_assign_no_init ::= store_annotation
|
ann_assign_no_init ::= store_annotation
|
||||||
store_annotation ::= LOAD_NAME STORE_ANNOTATION
|
store_annotation ::= LOAD_NAME STORE_ANNOTATION
|
||||||
|
store_annotation ::= subscript STORE_ANNOTATION
|
||||||
"""
|
"""
|
||||||
self.addRule(rule, nop_func)
|
self.addRule(rule, nop_func)
|
||||||
# Check to combine assignment + annotation into one statement
|
# Check to combine assignment + annotation into one statement
|
||||||
|
@@ -61,7 +61,7 @@ def customize_for_version36(self, version):
|
|||||||
'%c(%p)',
|
'%c(%p)',
|
||||||
(0, 'expr'), (1, 100)),
|
(0, 'expr'), (1, 100)),
|
||||||
'store_annotation': (
|
'store_annotation': (
|
||||||
'%|%[1]{pattr}: %c',
|
'%[1]{pattr}: %c',
|
||||||
0
|
0
|
||||||
),
|
),
|
||||||
'ann_assign_init_value': (
|
'ann_assign_init_value': (
|
||||||
|
Reference in New Issue
Block a user