PrettyUtil

Plain source file: base/pretty/PrettyUtil.hs (2009-01-04)

PrettyUtil is imported by: HsDeclPretty, HsGuardsPretty, HsTypePretty, UniqueNames, SourceNames, Pfe4Cmds.

module PrettyUtil where

--import SrcLoc
import PrettyPrint
import PrettySymbols(imp,lq,rq)


-- Pretty prints where declaration lists, also used in multiple places.
--ppWhere :: [Doc] -> Doc
ppWhere [] = empty
ppWhere ds = sep [kw "where",letNest (layout ds)]

-- Pretty prints contexts, if they are present
ppContext []  = empty
ppContext [c] = c <+> imp
ppContext cs  = ppiFTuple cs <+> imp

ppqIfDebug s = ppIfDebug (lq<>s<>rq)

Index

(HTML for this module was generated on 2009-01-04. About the conversion tool.)