Safe Haskell | None |
---|
- chr :: Vector v r => v r -> GChr r r
- chrLeft :: Vector v x => v x -> GChr (Maybe x, x) x
- chrLeftD :: Vector v x => x -> v x -> GChr (x, x) x
- chrRight :: Vector v x => v x -> GChr (x, Maybe x) x
- data GChr r x where
- newtype ZeroOne r x = ZeroOne {}
- zoLeft :: Vector v x => v x -> ZeroOne (Maybe x, x) x
- data GPeek r x = GPeek !(Vector x -> Int -> r) !(Vector x) !(Int :!: Int)
- data PeekL x = PeekL !(Vector x)
- peekL :: Vector x -> PeekL x
- data PeekR x = PeekR !(Vector x)
- peekR :: Vector x -> PeekR x
Documentation
chrLeft :: Vector v x => v x -> GChr (Maybe x, x) xSource
Parses a single character and returns the character to the left in a strict Maybe.
chrRight :: Vector v x => v x -> GChr (x, Maybe x) xSource
Parses a single character and returns the character to the right in a strict Maybe.
A generic Character parser that reads a single character but allows passing additional information.
(Monad m, Elms ls Subword, MkStream m ls Subword) => MkStream m (:!: ls (GChr r x)) Subword | |
(Monad m, TermElm m ts is) => TermElm m (Term ts (GChr r xs)) (:. is PointL) | NOTE This instance is currently the only one using an inline outer check. If This behaves well, it could be possible to put checks for valid indices inside the outerCheck function. (Currently disabled, as the compiler chokes on four-way alignments). |
(Monad m, TermElm m ts is) => TermElm m (Term ts (GChr r xs)) (:. is Subword) | |
Build (GChr r x) | |
ValidIndex ls Subword => ValidIndex (:!: ls (GChr r x)) Subword | |
Elms ls Subword => Elms (:!: ls (GChr r x)) Subword | |
TermValidIndex ts is => TermValidIndex (Term ts (GChr r xs)) (:. is PointL) | |
TermValidIndex ts is => TermValidIndex (Term ts (GChr r xs)) (:. is Subword) |
Wrapping a GChr to allow zero/one behaviour. Parses a character (or not) in a strict maybe.
Generalized peek.