diff mercurial/parser.py @ 29778:e5b794063fd4

parser: remove unused binding parameter from suffix action Because a suffix action never takes subsequent tokens, it should have no binding strength nor closing character. I've tried if this value could be used to resolve infix/suffix ambiguity of x^:y, but it appears not. So I decided to resend this patch.
author Yuya Nishihara <yuya@tcha.org>
date Sun, 05 Jul 2015 21:11:19 +0900
parents 8eba4cdcfd81
children 318a24b52eeb
line wrap: on
line diff
--- a/mercurial/parser.py	Wed Aug 10 16:27:33 2016 +0100
+++ b/mercurial/parser.py	Sun Jul 05 21:11:19 2015 +0900
@@ -65,7 +65,7 @@
             # handle infix rules, take as suffix if unambiguous
             infix, suffix = self._elements[token][3:]
             if suffix and not (infix and self._hasnewterm()):
-                expr = (suffix[0], expr)
+                expr = (suffix, expr)
             elif infix:
                 expr = (infix[0], expr, self._parseoperand(*infix[1:]))
             else: