Python 3 DUP_TOP_TWO bug

This commit is contained in:
rocky
2016-05-08 18:41:39 -04:00
parent dddb486d78
commit 196495c40e
4 changed files with 12 additions and 0 deletions

View File

@@ -332,6 +332,9 @@ class Python2Parser(PythonParser):
slice2 ::= expr expr DUP_TOPX_2 SLICE+2
slice3 ::= expr expr expr SLICE+3
slice3 ::= expr expr expr DUP_TOPX_3 SLICE+3
# In Python 3, DUP_TOPX_2 is DUP_TOP_TWO
binary_subscr2 ::= expr expr DUP_TOPX_2 BINARY_SUBSCR
'''
def add_custom_rules(self, tokens, customize):