[Haskell-cafe] Recursive attoparsec
Lian Hung Hon
hon.lianhung at gmail.com
Wed Oct 5 12:32:50 UTC 2016
Dear cafe,
Given
data Expression = ExpToken String | ExpAnd Expression Expression
How to write an attoparsec parser that parses this example:
"a" and "b" and "c"
into
ExpAnd (ExpToken "a") (ExpAnd (ExpToken "b") (ExpToken "c"))?
Regards,
Hon
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20161005/2ac93d48/attachment.html>
More information about the Haskell-Cafe
mailing list