megaparsec-4.4.0: Monadic parser combinators

Copyright© 2015–2016 Megaparsec contributors
LicenseFreeBSD
MaintainerMark Karpov <markkarpov@opmbx.org>
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

Text.Megaparsec.ShowToken

Description

Pretty printing function and instances for use in error messages.

Synopsis

Documentation

class Show a => ShowToken a where Source

Typeclass ShowToken defines single function showToken that can be used to “pretty-print” various tokens. By default, all commonly used instances are defined, but you can add your own, of course.

Methods

showToken :: a -> String Source

Pretty-print given token. This is used to get token representation for use in error messages.