You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-04 01:09:52 +08:00
Was mssing 2.5 cond3 semantic rule
This commit is contained in:
@@ -26,6 +26,8 @@ def customize_for_version25(self, version):
|
|||||||
# Import style for 2.5+
|
# Import style for 2.5+
|
||||||
########################
|
########################
|
||||||
TABLE_DIRECT.update({
|
TABLE_DIRECT.update({
|
||||||
|
'except_cond3' : ( '%|except %c, %c:\n',
|
||||||
|
(1, 'expr'), (-2, 'store') ),
|
||||||
'importmultiple': ( '%|import %c%c\n', 2, 3 ),
|
'importmultiple': ( '%|import %c%c\n', 2, 3 ),
|
||||||
'import_cont' : ( ', %c', 2 ),
|
'import_cont' : ( ', %c', 2 ),
|
||||||
# With/as is allowed as "from future" thing in 2.5
|
# With/as is allowed as "from future" thing in 2.5
|
||||||
|
@@ -34,7 +34,6 @@ def customize_for_version26_27(self, version):
|
|||||||
})
|
})
|
||||||
else:
|
else:
|
||||||
TABLE_DIRECT.update({
|
TABLE_DIRECT.update({
|
||||||
'except_cond3': ( '%|except %c, %c:\n', 1, 6 ),
|
|
||||||
'testtrue_then': ( 'not %p', (0, 22) ),
|
'testtrue_then': ( 'not %p', (0, 22) ),
|
||||||
|
|
||||||
})
|
})
|
||||||
|
@@ -1813,9 +1813,6 @@ class SourceWalker(GenericASTTraversal, object):
|
|||||||
node[-2][0].kind = 'unpack_w_parens'
|
node[-2][0].kind = 'unpack_w_parens'
|
||||||
self.default(node)
|
self.default(node)
|
||||||
|
|
||||||
# except_cond3 is only in Python <= 2.6
|
|
||||||
n_except_cond3 = n_except_cond2
|
|
||||||
|
|
||||||
def template_engine(self, entry, startnode):
|
def template_engine(self, entry, startnode):
|
||||||
"""The format template interpetation engine. See the comment at the
|
"""The format template interpetation engine. See the comment at the
|
||||||
beginning of this module for the how we interpret format
|
beginning of this module for the how we interpret format
|
||||||
|
Reference in New Issue
Block a user