4/20/2026 at 8:08:06 AM
You can ignore precedence in the grammar, and then use a pratt parser or shunting yard or something to parse the precedence.But yes, it does need it, usually. And it's not a huge thing to implement. I usually implement it in the grammar, with inline node folding inserted for left associative operators, which gets me a very nice clean AST.
by vrighter