Hi

I was wondering if it was possible to write a function that allows changing 
the state type of the Parser monad from Parsec.

The full parser type is: GenParser p s a, where p is the token type, s is the 
state type and a is the return type of the monad. However, I mostly use 
CharParser s a which is a synonym for GenParser Char s a.

What I would like is a function that allows me to combine CharParsers with 
differing state types. Something like:

runParser' :: CharParser t a -> t -> CharParser s (t,a)

So that I can use parsers written to work with different state types together 
on the same input stream.

Does anybody know if this is possible, or how one might do it with Parsec?

Thanks

John
_______________________________________________
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to