summaryrefslogtreecommitdiffstats
path: root/Grammar
diff options
context:
space:
mode:
authorPablo Galindo <Pablogsal@gmail.com>2020-10-31 00:40:42 (GMT)
committerGitHub <noreply@github.com>2020-10-31 00:40:42 (GMT)
commitddcd57e3ea75ab0ad370bbaaa6b76338edbca395 (patch)
treead2dc28a4ee0ccb922517d4af8a868a3ce19d08a /Grammar
parent09c6120be8c70366495b027ae3daa213609de3ed (diff)
downloadcpython-ddcd57e3ea75ab0ad370bbaaa6b76338edbca395.zip
cpython-ddcd57e3ea75ab0ad370bbaaa6b76338edbca395.tar.gz
cpython-ddcd57e3ea75ab0ad370bbaaa6b76338edbca395.tar.bz2
[3.9] bpo-42214: Fix check for NOTEQUAL token in the PEG parser for the barry_as_flufl rule (GH-23048) (GH-23051)
(cherry picked from commit 06f8c3328dcd81c84d1ee2b3a57b5381dcb38482) Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Diffstat (limited to 'Grammar')
-rw-r--r--Grammar/python.gram2
1 files changed, 1 insertions, 1 deletions
diff --git a/Grammar/python.gram b/Grammar/python.gram
index b709d3d..60eeb36 100644
--- a/Grammar/python.gram
+++ b/Grammar/python.gram
@@ -413,7 +413,7 @@ compare_op_bitwise_or_pair[CmpopExprPair*]:
| is_bitwise_or
eq_bitwise_or[CmpopExprPair*]: '==' a=bitwise_or { _PyPegen_cmpop_expr_pair(p, Eq, a) }
noteq_bitwise_or[CmpopExprPair*]:
- | (tok='!=' {_PyPegen_check_barry_as_flufl(p) ? NULL : tok}) a=bitwise_or {_PyPegen_cmpop_expr_pair(p, NotEq, a) }
+ | (tok='!=' { _PyPegen_check_barry_as_flufl(p, tok) ? NULL : tok}) a=bitwise_or {_PyPegen_cmpop_expr_pair(p, NotEq, a) }
lte_bitwise_or[CmpopExprPair*]: '<=' a=bitwise_or { _PyPegen_cmpop_expr_pair(p, LtE, a) }
lt_bitwise_or[CmpopExprPair*]: '<' a=bitwise_or { _PyPegen_cmpop_expr_pair(p, Lt, a) }
gte_bitwise_or[CmpopExprPair*]: '>=' a=bitwise_or { _PyPegen_cmpop_expr_pair(p, GtE, a) }