Re:We Need to Know LR and Recursive Descent Parsing Techniques
by olliej on Tuesday January 17, 2023 @01:52PM
(#34416906)
Ehn, the problem with LR parsing is that it’s terribly slow and can only practically be done via generators, and I have yet to encounter a parser generator that can actually handle error correction properly (necessary if you want anything other than the first error to break everything after).
The theoretical argument for LR parsing is it is more powerful than LL, LALR, etc because PLT seems hell bent on ignoring LL* because of the arbitrary restrictions placed on what a “real” BNF grammar is allowed to do.
Knowing about LR - and PDA/state machine based parsing is useful, but pretending that LR parsers are somehow better than recursive descent is nonsense.
The theoretical argument for LR parsing is it is more powerful than LL, LALR, etc because PLT seems hell bent on ignoring LL* because of the arbitrary restrictions placed on what a “real” BNF grammar is allowed to do.
Knowing about LR - and PDA/state machine based parsing is useful, but pretending that LR parsers are somehow better than recursive descent is nonsense.