[Haskell-cafe] parsec manyTill documentation question

Stephen Tetley stephen.tetley at gmail.com
Sat Sep 25 03:34:36 EDT 2010

On 25 September 2010 05:30, Evan Laforge <qdunkan at gmail.com> wrote:

> I thought the parsec source included some example parsers for simple
> languages?  In any case, there is lots of material floating around,
> [Snip]

The best documentation is Daan Leijen's original manual, plus the
original source distribution which has example parsers for Henk, Tiger
and Mondrain.

Both are available from here - the original poster was working with
the HTML version of the manual - there is also a PDF version:


It would be nice if the Hackage package added the examples back into
the distribution.

The parser in the Scheme in 48 hours tutorial isn't a great example of
Parsec as it doesn't use the Token module. Not using the Token module
means the Scheme parser does hacky things such as parseNumber which
uses /read/ - this is double work, Parsec already handles numbers, it
doesn't need to call out to another parser (Haskell's builtin read).


More information about the Haskell-Cafe mailing list