More Python version tuple comparison conversion

This commit is contained in:
rocky
2021-10-16 11:41:22 -04:00
parent e8e006bb8c
commit 15efaffe8d
15 changed files with 23 additions and 23 deletions

View File

@@ -89,7 +89,7 @@ class Python25Parser(Python26Parser):
return_stmt_lambda LAMBDA_MARKER
""")
super(Python25Parser, self).customize_grammar_rules(tokens, customize)
if self.version == 2.5:
if self.version[:2] == (2, 5):
self.check_reduce["try_except"] = "tokens"
self.check_reduce["aug_assign1"] = "AST"
self.check_reduce["ifelsestmt"] = "AST"