Skip to content

Instantly share code, notes, and snippets.

View rovaughn's full-sized avatar

Alec Newman rovaughn

View GitHub Profile
-- A `Parser a` either parses a ParseState into (1) a value of type `a` with the
-- new ParseState or (2) an error with the location of the error and a
-- messagelocation of the error and a message
newtype Parser a = Parser {
parse :: ParseState -> ParseResult a
}
data ParseState = ParseState {
location :: Int,
string :: String
### Keybase proof
I hereby claim:
* I am rovaughn on github.
* I am rovaughn (https://keybase.io/rovaughn) on keybase.
* I have a public key ASAAzAWzAOSwE1C6YLVF_V988I95HePdmyzcqsLpJc8MQwo
To claim this, I am signing this object: