on 63243ca help sign in
elk/compiler/Type/PrettyPrint.hs
16 lines 322 B history raw
2module Type.PrettyPrint where
4import Text.PrettyPrint
5import qualified SourceSyntax.PrettyPrint as Src
7data ParensWhen = Fn | App | Never
9class PrettyType a where
10 pretty :: ParensWhen -> a -> Doc
12commaSep docs = sep (punctuate comma docs)
14parensIf bool doc = if bool then parens doc else doc
16reprime = Src.reprime