
25 Mar
2008
25 Mar
'08
11:47 a.m.
Paul Keir wrote:
I’m having some difficulty using the Parsec library, perhaps you could help. I’ve reduced my problem as shown below. I would like the ‘only_prod’ parser to require the reserved string “only”, _optionally_ followed by an identifier. As part of ‘mytest’, this should then be followed by the reserved string “end”.
Look into option, optional, and optionMaybe.