Text.Pandoc.Error

pandoc-1.18: Conversion between markup formats

Copyright | Copyright (C) 2006-2016 John MacFarlane
License | GNU GPL, version 2 or above
Maintainer | John MacFarlane <jgm@berkeley.edu>
Stability | alpha
Portability | portable
Safe Haskell | None
Language | Haskell98

Text.Pandoc.Error

Description

This module provides a standard way to deal with possible errors encounted during parsing.

Synopsis

- data PandocError
  - = ParseFailure String
  - | ParsecError Input ParseError
- handleError :: Either PandocError a -> a

# Documentation

data PandocError #

Constructors

ParseFailure String | Generic parse failure
ParsecError Input ParseError | Error thrown by a Parsec parser

Instances

Show PandocError # |
Methods showsPrec :: Int -> PandocError -> ShowS # show :: PandocError -> String # showList :: [PandocError] -> ShowS #
Generic PandocError # |
Associated Types type Rep PandocError :: * -> * # Methods from :: PandocError -> Rep PandocError x # to :: Rep PandocError x -> PandocError #
Exception PandocError # |
Methods toException :: PandocError -> SomeException # fromException :: SomeException -> Maybe PandocError # displayException :: PandocError -> String #
type Rep PandocError # |
type Rep PandocError

handleError :: Either PandocError a -> a #

An unsafe method to handle `PandocError`s.