Sdf2HaskellContentsIndex
GPP
Synopsis
type GPP = forall a . Term a => a -> Doc
type TUDoc = TU Doc Identity
class PP a where
pp :: GPP -> a -> Doc
type UPP = GPP -> TUDoc
gppList :: Term a => GPP -> [a] -> Doc
gppListSep :: (Term sep, Term a) => GPP -> sep -> [a] -> Doc
gppMaybe :: Term a => GPP -> Maybe a -> Doc
gppEither :: (Term a, Term b) => GPP -> Either a b -> Doc
renderFix :: Term a => UPP -> a -> String
type MonoPP a = a -> Doc
adhocQ :: (Term t, Monad m) => TU a m -> (t -> a) -> TU a m
Documentation
type GPP = forall a . Term a => a -> Doc
The type of generic pretty-printers (universally quantified).
type TUDoc = TU Doc Identity
The type of generic pretty-printers (as TU strategy)
class PP a where
Class of pre-fix-pointed pretty-printers (overloaded)
Methods
pp :: GPP -> a -> Doc
Instances
PP String
PP Grammar
PP Alias
PP Aliases
PP Lookahead
PP Lookaheads
PP Restriction
PP Restrictions
PP Attribute
PP OptExp
PP RealCon
PP AFun
PP ATerm'
PP Symbol
PP Literal
PP Production
PP Character
PP CharRange
PP CharRanges
PP OptCharRanges
PP CharClass
PP Associativity
PP Group
PP Priority
PP Priorities
PP IntCon
PP Renamings
PP Renaming
PP Definition
PP Module
PP Section
PP Sections
PP ModuleName
PP ImpSection
PP Imports
PP Import
PP Symbols
PP Attributes
PP Productions
PP SDF
type UPP = GPP -> TUDoc
Type of updatable pretty-printers.
gppList :: Term a => GPP -> [a] -> Doc
Helper function for pretty-printing lists.
gppListSep :: (Term sep, Term a) => GPP -> sep -> [a] -> Doc
Helper function for pretty-printing separator lists.
gppMaybe :: Term a => GPP -> Maybe a -> Doc
Helper function for pretty-printing optionals.
gppEither :: (Term a, Term b) => GPP -> Either a b -> Doc
Helper function for pretty-printing alternatives.
renderFix :: Term a => UPP -> a -> String
Render with the fix-point of a pre-fix-point pretty-printer
type MonoPP a = a -> Doc
For easy type annotation
adhocQ :: (Term t, Monad m) => TU a m -> (t -> a) -> TU a m
For easy non-monadic adhoc
Produced by Haddock version 0.6