Copyright | (c) Edward Kmett 2011-2019 |
---|---|
License | BSD3 |
Maintainer | ekmett@gmail.com |
Stability | experimental |
Portability | non-portable |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Text.Trifecta.Result
Contents
Description
Results and Parse Errors
Synopsis
- data Result a
- class AsResult s t a b | s -> a, t -> b, s b -> t, t a -> s where
- foldResult :: (ErrInfo -> b) -> (a -> b) -> Result a -> b
- _Success :: AsResult s t a b => Prism s t a b
- _Failure :: AsResult s s a a => Prism' s ErrInfo
- data Err = Err {}
- class HasErr c where
- class Errable m where
- data ErrInfo = ErrInfo {
- _errDoc :: Doc AnsiStyle
- _errDeltas :: [Delta]
- explain :: Rendering -> Err -> Doc AnsiStyle
- failed :: String -> Err
Parse Results
The result of parsing. Either we succeeded or something went wrong.
Instances
Parsing Errors
This is used to report an error. What went wrong, some supplemental docs and a set of things expected at the current location. This does not, however, include the actual location.
Constructors
Err | |
Minimal complete definition