What is the advantage of using a parser generator like happy as opposed to using parser combinators?

后端 未结 5 1268
情歌与酒
情歌与酒 2021-01-31 17:44

To learn how to write and parse a context-free grammar I want to choose a tool. For Haskell, there are two big options: Happy, which generates a parser from a grammar descriptio

5条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-31 18:20

    I'm used to the parser combinator library uu-parsinglib from utrecht university. One can have error correcting and permutations for free, and also the things that parsec has. I also like it because my implemented grammar looks like an EBNF grammar, without so much monadic stuff, and is easy to read.

提交回复
热议问题