Chris's Wiki :: blog/programming/WhyRDParsersForMe
Today I read Laurence Tratt's Which Parsing Approach? (via), which has a decent overview of how parsing computer languages (including little domain specific languages) is not quite the well solved problem we'd like it to be. As part of the article, Tratt discusses how recursive descent parsers have a number of issues in practice and recommends using other things, such as a LR parser generator. I have a long standing interest in parsing, I'm reasonably well aware of the annoyances of recursive descent parsers (although some of the issues Tratt raised hadn't occurred to me before now), and I've been exposed to parser generators like Yacc. Despite that, my normal approach to parsing any new little language for real is to write a recursive descent parser in whatever language I'm using, and Tratt's article is not going to change that. My choice here is for entirely pragmatic reasons, because to me recursive descent parsers generally have two significant advantages over all other real parser
Why I write recursive descent parsers (despite their issues) September 16, 2020 Today I read Laurence Tratt's Which Parsing Approach? (via), which has a decent overview of how parsing computer languages (including little domain specific languages) is not quite the well solved problem we'd like it to be. As part of the article, Tratt discusses how recursive descent parsers have a number of issues in practice and recommends using other things, such as a LR parser generator. I have a long standing interest in parsing, I'm reasonably well aware of the annoyances of recursive descent parsers…
saved by
related reading
- Laurence Tratt: Which Parsing Approach?tratt.net
- CS [45]12[01] Spring 2023courses.cs.cornell.edu
- Reading 12: Regular Expressions & Grammarsweb.mit.edu
- Parsing Expressions · Crafting Interpreterscraftinginterpreters.com
- Reading 19: Parsersweb.mit.edu
- One way to do applied researchdubroy.com
- Reading 19: Little Languagesweb.mit.edu
- Things unlearnedscattered-thoughts.net
- Introduction · Crafting Interpreterscraftinginterpreters.com
- I wrote a programming language. Here’s how you can, too.freecodecamp.org
- Context-free grammar - Wikipediaen.wikipedia.org
- Pratt Parsers: Expression Parsing Made Easy - journal.stuffwithstuff.comjournal.stuffwithstuff.com