I have a left-recursive rule like the following:
EXPRESSION : EXPRESSION BINARYOP EXPRESSION | UNARYOP EXPRESSION | NUMBER;
I need to add parens to it but i'm not sure how to make a left parens depend on a matching right parens yet still optional. Can someone show me how? (or am i trying to do entirely too much in lexing, and should i leave some or all of this to the parsing?)