Karya, built on Sun Nov 26 01:04:37 PST 2017 (patch 0a920b2bde70c0cbac8ee09d158064798b61bbe5)

Safe HaskellNone

Derive.Sig2

Synopsis

Documentation

data Parser a Source #

Constructors

Parser 

Fields

Instances

Functor Parser # 

Methods

fmap :: (a -> b) -> Parser a -> Parser b #

(<$) :: a -> Parser b -> Parser a #

Applicative.Applicative Parser # 

Methods

pure :: a -> Parser a #

(<*>) :: Parser (a -> b) -> Parser a -> Parser b #

(*>) :: Parser a -> Parser b -> Parser b #

(<*) :: Parser a -> Parser b -> Parser a #

Applicative.Alternative Parser # 

Methods

empty :: Parser a #

(<|>) :: Parser a -> Parser a -> Parser a #

some :: Parser a -> Parser [a] #

many :: Parser a -> Parser [a] #

type Parse a = State -> ([Error], Either Error (State, Maybe a)) Source #

Collect errors persistently.

type Docs = [ArgDoc] Source #

data State Source #

Constructors

State 

Fields

try :: Parser a -> Parser a Source #

Turn a failed parse into a successful empty parse, but remember the error. This means thet (|) will try an alternative.