
6 Sep
2010
6 Sep
'10
8:03 p.m.
On Mon, Sep 6, 2010 at 2:45 PM, Olle Fredriksson
expr :: Grammar Char E expr = do rec e <- rule [ Plus <@> e <# '+' <#> t , id <@> t ] t <- rule [ Times <@> t <# '*' <#> f , id <@> f ] f <- rule [ id <@ '(' <#> e <# ')' , Var <@ 'x' ] return e
Looks like Applicative style. This is good, even while I don't really know why we are seeing <@> and <#> instead of <$> and <*>. How does Grempa compare with other parsing libraries/tools, such as Parsec, Attoparsec and Happy, with regard to ease of use and performance? Cheers! =) -- Felipe.