replacing guile with haskell?

Derek Elkins ddarius at
Tue Oct 21 21:21:26 EDT 2003

On Tue, 21 Oct 2003 13:47:51 +0100
Graham Klyne <GK at> wrote:

> At 04:17 21/10/03 -0400, ajb at wrote:
> >I think I might have mentioned this previously, but here's an
> >interesting implementation of Knuth-Morris-Pratt substring searching
> >(which is indeed a "little language") which illustrates something or
> >other:
> >
> >
> Nice.  Do you know if anyone has done anything like this for regular 
> expressions?  I'm thinking in particular that a function that turned a
> regular expression into a Parsec parser function could be useful, as
> in:
>     regexp.compile :: String -> GenParser Char st [String]
> where GenParser is defined by the Parsec library [1], and the parsed
> result is a list of substrings corresponding to the (...) parts of the
> regexp (if matched, of course).  (The parser result type might warrant
> some refinement.)

This page is full of strange and wonderful things,

How 'bout the Haskell Dynamic Lexer Engine

It doesn't create a Parsec parser, but it would be very easy to make a
function with it that did.

More information about the Haskell-Cafe mailing list