nest-0.0.2

Safe HaskellSafe
LanguageHaskell2010

Nest

Contents

Synopsis

Errors

Types

newtype Parser m a Source #

Constructors

Parser 

Instances

MonadTrans Parser Source # 

Methods

lift :: Monad m => m a -> Parser m a #

Monad m => Monad (Parser m) Source # 

Methods

(>>=) :: Parser m a -> (a -> Parser m b) -> Parser m b #

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

return :: a -> Parser m a #

fail :: String -> Parser m a #

Functor m => Functor (Parser m) Source # 

Methods

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

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

Monad m => Applicative (Parser m) Source # 

Methods

pure :: a -> Parser m a #

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

liftA2 :: (a -> b -> c) -> Parser m a -> Parser m b -> Parser m c #

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

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

MonadIO m => MonadIO (Parser m) Source # 

Methods

liftIO :: IO a -> Parser m a #

Basic parsers

numeric :: (Monad m, Read n, Num n) => ByteString -> Parser m n Source #

flag :: Monad m => ByteString -> a -> a -> Parser m a Source #

Combinators for enriching parsers

option :: Monad m => Parser m a -> Parser m (Maybe a) Source #

withDefault :: Monad m => Parser m a -> a -> Parser m a Source #

withContext :: Monad m => Parser m a -> Text -> Parser m a Source #

Run parsers with environment

run :: MonadIO m => Parser m a -> m (Either NestError a) Source #

force :: MonadIO m => Parser m a -> m a Source #