4 ms·
I too have had great experiences from doing recursive descent. I don't understand why so many people don't like it. The techniques for handling left- and right
by cuspycode 6y ago
I too have had great experiences from doing recursive descent. I don't understand why so many people don't like it. The techniques for handling left- and right associativity of infix operators have been well known since many decades, so I am surprised that the original article thinks it is still an issue. But I have met some people who felt uncomfortable by recursive descent parsers that were implemented via recursive procedure calls, just because they didn't quite understand recursive procedure calls in the first place. So maybe that's part of the reason.
- userbinator 6y agoMy experience has been that those who don't like RD have a mostly theoretical/academic background and are likewise similarly unimpressed with "simple" or "unsophisticated" code in general.
- afiori 6y agoFor the author his case against RD is not for the implementation. At the end of the articles he calls for LR reference grammars (I imagine both for fuzzy testing and documentation) to ensure that your perfectly usable RD parser with nice error messages does not miss some edge cases.
- tomp 6y ago> I don't understand why so many people don't like it. 2 reasons: - it doesn’t warn you about ambiguous grammar, so you don’t know when you screw up - it requires a lot of boilerplate for operator precedence (one function for each level), in a LR parser generator that’s trivial so I can spend time on more important things