If LR parsing is such a beautiful theory, why do the tools that implement it feel like such terrible hacks?
Conversation
Yes. Currently dealing with menhir, an OCaml version of yacc.
2
1
I haven't found LALRPOP too terrible, tbh. But I've not use YACC or Menhir before so it's hard to compare... in what way do they feel hacky?
1. Everything to do with precedence.
2. Error-handling feels very tacked-on
3. The docs talk in terms of the machine your rules compile to ("state", "shift", "reduce"). There's no abstract or denotational understanding, only an operational one.
1

