Python 3.3 added a an additional LOAD_STR before MAKE_FUNCTION and this has an effect on many rules.
(self, rule, opname, attr, customize)
| 640 | self.add_unique_rule(rule, token.kind, uniq_param, customize) |
| 641 | |
| 642 | def add_make_function_rule(self, rule, opname, attr, customize): |
| 643 | """Python 3.3 added a an additional LOAD_STR before MAKE_FUNCTION and |
| 644 | this has an effect on many rules. |
| 645 | """ |
| 646 | if self.version >= (3, 3): |
| 647 | load_op = "LOAD_STR " |
| 648 | |
| 649 | new_rule = rule % ((load_op) * 1) |
| 650 | else: |
| 651 | new_rule = rule % (("LOAD_STR ") * 0) |
| 652 | self.add_unique_rule(new_rule, opname, attr, customize) |
| 653 | |
| 654 | def customize_grammar_rules(self, tokens, customize): |
| 655 | """The base grammar we start out for a Python version even with the |
no test coverage detected