This library contains a simple pretty printer for showing Go programs.
Author: Jonas Boehm
Version: November 2020
showGoExpr
:: GoExpr -> String
Shows a Go expression as a string in Go syntax. |
showGoStat
:: Int -> GoStat -> String
Shows a Go statement as a string in Go syntax with indenting. |
goShowExprBranch
:: Int -> GoExprBranch -> String
Shows a Go expression branch as a String in Go Syntax. |
showGoProg
:: GoProg -> String
Shows a Go program as a string in Go syntax. |
showGoImports
:: [String] -> String
Shows a list of imports as a string in Go syntax. |
showGoTopLevelDecl
:: GoTopLevelDecl -> String
Shows a Go top-level declaration as a string in Go syntax. |
showGoFuncDecl
:: GoFuncDecl -> String
Shows a Go function declaration as a string in Go syntax. |
showGoParam
:: GoParam -> String
Shows a Go parameter as a string in Go syntax. |
showGoCommaList
:: (a -> String) -> [a] -> String
Shows a List of a Go type as a comma separated list in go syntax. |
indent
:: Int -> String
Creates a string of blanks with length 4*n |
Shows a Go expression as a string in Go syntax. |
Shows a Go statement as a string in Go syntax with indenting.
|
Shows a Go expression branch as a String in Go Syntax.
|
Shows a Go program as a string in Go syntax. |
Shows a list of imports as a string in Go syntax. |
Shows a Go top-level declaration as a string in Go syntax. |
Shows a Go function declaration as a string in Go syntax. |
Shows a Go parameter as a string in Go syntax. |
Shows a List of a Go type as a comma separated list in go syntax.
|
Creates a string of blanks with length 4*n |