I am trying to parse recursive expressions in ANTLR such as:
(a + (b + C))
or
((a + b))
I read this supposed solution: ANTLR Grammar for expressions
However when I try to create a rule such as:
ParenthesisExpression: '(' (ParenthesisExpression | Expression) ')';
ANTLR complains that "Rule ParenthesisExpression is left-recursive".
How can I parse expressions that can have within themselves, subexpressions of the same form?