Parsing: Generalized state type on readWith.

This commit is contained in:
John MacFarlane 2013-06-20 20:28:50 -07:00
parent a2b98ba218
commit a578a490ee

View file

@ -764,9 +764,9 @@ gridTableFooter = blanklines
---
-- | Parse a string with a given parser and state.
readWith :: Parser [Char] ParserState a -- ^ parser
-> ParserState -- ^ initial state
-> [Char] -- ^ input
readWith :: Parser [Char] st a -- ^ parser
-> st -- ^ initial state
-> [Char] -- ^ input
-> a
readWith parser state input =
case runParser parser state "source" input of