Add generator expression Python 3.0 .. 3.2

This commit is contained in:
rocky
2022-11-05 10:31:00 -04:00
parent 9d1cf50c5e
commit 8843686b49
3 changed files with 4 additions and 3 deletions

View File

@@ -19,8 +19,9 @@ class Python33Parser(Python32Parser):
def customize_grammar_rules(self, tokens, customize):
self.remove_rules("""
# 3.3+ adds POP_BLOCKS
whileTruestmt ::= SETUP_LOOP l_stmts_opt JUMP_BACK NOP COME_FROM_LOOP
genexpr_func ::= LOAD_ARG FOR_ITER store comp_iter JUMP_BACK
whileTruestmt ::= SETUP_LOOP l_stmts_opt JUMP_BACK POP_BLOCK NOP COME_FROM_LOOP
whileTruestmt ::= SETUP_LOOP l_stmts_opt JUMP_BACK NOP COME_FROM_LOOP
""")
super(Python33Parser, self).customize_grammar_rules(tokens, customize)
return