Was mssing 2.5 cond3 semantic rule

This commit is contained in:
rocky
2019-04-23 13:07:30 -04:00
parent c6bdfdd592
commit 636257f879
3 changed files with 2 additions and 4 deletions

View File

@@ -26,6 +26,8 @@ def customize_for_version25(self, version):
# Import style for 2.5+
########################
TABLE_DIRECT.update({
'except_cond3' : ( '%|except %c, %c:\n',
(1, 'expr'), (-2, 'store') ),
'importmultiple': ( '%|import %c%c\n', 2, 3 ),
'import_cont' : ( ', %c', 2 ),
# With/as is allowed as "from future" thing in 2.5

View File

@@ -34,7 +34,6 @@ def customize_for_version26_27(self, version):
})
else:
TABLE_DIRECT.update({
'except_cond3': ( '%|except %c, %c:\n', 1, 6 ),
'testtrue_then': ( 'not %p', (0, 22) ),
})

View File

@@ -1813,9 +1813,6 @@ class SourceWalker(GenericASTTraversal, object):
node[-2][0].kind = 'unpack_w_parens'
self.default(node)
# except_cond3 is only in Python <= 2.6
n_except_cond3 = n_except_cond2
def template_engine(self, entry, startnode):
"""The format template interpetation engine. See the comment at the
beginning of this module for the how we interpret format