language-boogie-0.1.1: Interpreter and language infrastructure for Boogie.

Safe HaskellSafe-Inferred

Language.Boogie.PrettyPrinter

Contents

Description

Pretty printer for Boogie 2

Synopsis

Pretty-printing programs

programDoc :: Program -> DocSource

Pretty-printed program

renderWithTabs :: Doc -> StringSource

Render document with tabs instead of spaces

typeDoc :: Type -> DocSource

Pretty-printed type

exprDoc :: Expression -> DocSource

Pretty-printed expression

statementDoc :: Statement -> DocSource

Pretty-printed statement

declDoc :: Decl -> DocSource

Pretty-printed top-level declaration

Utility

newline :: DocSource

New line

vsep :: [Doc] -> DocSource

Separate by new lines

commaSep :: [Doc] -> DocSource

Separate by commas

angles :: Doc -> DocSource

Enclose in < >

spaces :: Doc -> DocSource

Enclose in spaces

option :: Bool -> Doc -> DocSource

Conditionally produce a doc

optionMaybe :: Maybe t -> (t -> Doc) -> DocSource

Convert a Just value to doc

unOpDoc :: UnOp -> DocSource

Pretty-printed unary operator

binOpDoc :: BinOp -> DocSource

Pretty-printed binary operator

sigDoc :: [Type] -> [Type] -> DocSource

Pretty-printed function or procedure signature