parsley-core-1.6.0.0: A fast parser combinator library backed by Typed Template Haskell
LicenseBSD-3-Clause
MaintainerJamie Willis
Stabilityexperimental
Safe HaskellNone
LanguageHaskell2010

Parsley.Internal.Core.InputTypes

Description

Extra types of input specialised for specific scenarios.

Since: 1.0.0.0

Synopsis

Documentation

data Stream Source #

An input type that represents an infinite stream of input characters.

Since: 0.1.0.0

Constructors

!Char :> Stream 

Instances

Instances details
InputPrep Stream Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.InputOps

Methods

prepare :: forall (rep :: TYPE (RepKind Stream)). rep ~ Rep Stream => Code Stream -> Code (InputDependant rep) Source #

MarshalOps Stream Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

RecBuilder Stream Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Methods

bindIterHandler# :: (Code (Rep Stream) -> StaHandler# s Stream a) -> (Code (Rep Stream -> Handler# s Stream a) -> Code b) -> Code b Source #

bindIter# :: Code (Rep Stream) -> (DynHandler s Stream a -> Code (Rep Stream) -> Code (ST s (Maybe a))) -> Code (ST s (Maybe a)) Source #

bindRec# :: (DynSubroutine s Stream a x -> DynCont s Stream a x -> Code (Rep Stream) -> DynHandler s Stream a -> Code (ST s (Maybe a))) -> DynSubroutine s Stream a x Source #

JoinBuilder Stream Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Methods

setupJoinPoint# :: StaCont# s Stream a x -> (DynCont s Stream a x -> Code b) -> Code b Source #

HandlerOps Stream Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Methods

bindHandler# :: StaHandler# s Stream a -> (DynHandler s Stream a -> Code b) -> Code b Source #

Input Stream Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine

PositionOps (# Int#, Stream #) Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.InputOps

Methods

same :: Code (# Int#, Stream #) -> Code (# Int#, Stream #) -> Code Bool Source #

shiftRight :: Code (# Int#, Stream #) -> Code Int# -> Code (# Int#, Stream #) Source #

newtype CharList Source #

By wrapping a regular String with this newtype, Parsley will not preprocess it into an array of characters, instead using regular pattern matching for the implementation.

Since: 0.1.0.0

Constructors

CharList String 

Instances

Instances details
InputPrep CharList Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.InputOps

Methods

prepare :: forall (rep :: TYPE (RepKind CharList)). rep ~ Rep CharList => Code CharList -> Code (InputDependant rep) Source #

MarshalOps CharList Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

RecBuilder CharList Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

JoinBuilder CharList Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Methods

setupJoinPoint# :: StaCont# s CharList a x -> (DynCont s CharList a x -> Code b) -> Code b Source #

HandlerOps CharList Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Input CharList Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine

newtype Text16 Source #

By wrapping a regular Text input with this newtype, Parsley will assume that all of the characters fit into exactly one 16-bit chunk. This allows the consumption of characters in the datatype to be consumed much faster, but does not support multi-word characters.

Since: 0.1.0.0

Constructors

Text16 Text 

Instances

Instances details
InputPrep Text16 Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.InputOps

Methods

prepare :: forall (rep :: TYPE (RepKind Text16)). rep ~ Rep Text16 => Code Text16 -> Code (InputDependant rep) Source #

MarshalOps Text16 Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

RecBuilder Text16 Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Methods

bindIterHandler# :: (Code (Rep Text16) -> StaHandler# s Text16 a) -> (Code (Rep Text16 -> Handler# s Text16 a) -> Code b) -> Code b Source #

bindIter# :: Code (Rep Text16) -> (DynHandler s Text16 a -> Code (Rep Text16) -> Code (ST s (Maybe a))) -> Code (ST s (Maybe a)) Source #

bindRec# :: (DynSubroutine s Text16 a x -> DynCont s Text16 a x -> Code (Rep Text16) -> DynHandler s Text16 a -> Code (ST s (Maybe a))) -> DynSubroutine s Text16 a x Source #

JoinBuilder Text16 Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Methods

setupJoinPoint# :: StaCont# s Text16 a x -> (DynCont s Text16 a x -> Code b) -> Code b Source #

HandlerOps Text16 Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine.BindingOps

Methods

bindHandler# :: StaHandler# s Text16 a -> (DynHandler s Text16 a -> Code b) -> Code b Source #

Input Text16 Source # 
Instance details

Defined in Parsley.Internal.Backend.Machine

nomore :: Stream Source #

The "end" of a stream, an infinite stream of '\0' (null) characters

Since: 0.1.0.0