Karya, built on Mon Jul 24 11:39:07 PDT 2017 (patch 33511aca01257b76b88de7c7a2763b7a965c084e)

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.