attoparsec-run-0.0.0.0: Conveniently run Attoparsec parsers
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Attoparsec.Run

Synopsis

Documentation

data FinalResult i a Source #

Constructors

FinalResult 

Fields

  • i

    Remaining unparsed input

  • (Either ParseError a)

    Either an error or a successfully parsed value

Instances

Instances details
(Show i, Show a) => Show (FinalResult i a) Source # 
Instance details

Defined in Data.Attoparsec.Run

Methods

showsPrec :: Int -> FinalResult i a -> ShowS #

show :: FinalResult i a -> String #

showList :: [FinalResult i a] -> ShowS #

(Eq i, Eq a) => Eq (FinalResult i a) Source # 
Instance details

Defined in Data.Attoparsec.Run

Methods

(==) :: FinalResult i a -> FinalResult i a -> Bool #

(/=) :: FinalResult i a -> FinalResult i a -> Bool #

(Ord i, Ord a) => Ord (FinalResult i a) Source # 
Instance details

Defined in Data.Attoparsec.Run

Methods

compare :: FinalResult i a -> FinalResult i a -> Ordering #

(<) :: FinalResult i a -> FinalResult i a -> Bool #

(<=) :: FinalResult i a -> FinalResult i a -> Bool #

(>) :: FinalResult i a -> FinalResult i a -> Bool #

(>=) :: FinalResult i a -> FinalResult i a -> Bool #

max :: FinalResult i a -> FinalResult i a -> FinalResult i a #

min :: FinalResult i a -> FinalResult i a -> FinalResult i a #

finalizeResult Source #

Arguments

:: IResult i a

Must be either Done or Fail, not Partial

-> FinalResult i a 

data ParseError Source #

Constructors

ParseError 

Fields

  • [String]

    A list of contexts in which the error occurred

  • String

    The message describing the error, if any

showParseError :: ParseError -> String Source #

Format a parse error in a matter suitable for displaying in log output

data BufferedInput m i Source #

Constructors

BufferedInput 

Fields

  • i

    Initial input

  • (m i)

    Should return an empty string once the end of input is reached

data RestorableInput m i Source #

Constructors

RestorableInput 

Fields

  • (m i)

    Return an empty string once the end of input is reached

  • (i -> m ())

    Return a non-empty chunk of input to the input stream