curry-base-1.1.1: Functions for manipulating Curry programs

Copyright(c) 1999 - 2004 Wolfgang Lux
2005 Martin Engelke
2011 - 2015 Björn Peemöller
2016 Finn Teegen
LicenseBSD-3-clause
Maintainerbjp@informatik.uni-kiel.de
Stabilityexperimental
Portabilityportable
Safe HaskellSafe
LanguageHaskell2010

Curry.Syntax.Pretty

Description

This module implements a pretty printer for Curry expressions. It was derived from the Haskell pretty printer provided in Simon Marlow's Haskell parser.

Synopsis

Documentation

ppModule :: Module a -> Doc Source #

Pretty print a module

ppInterface :: Interface -> Doc Source #

Pretty print an interface

ppIDecl :: IDecl -> Doc Source #

Pretty print an interface declaration

ppDecl :: Decl a -> Doc Source #

Pretty print a declaration

ppIdent :: Ident -> Doc Source #

Pretty print an identifier

ppPattern :: Int -> Pattern a -> Doc Source #

Pretty print a constructor term

ppFieldPatt :: Field (Pattern a) -> Doc Source #

Pretty print a record field pattern

ppExpr :: Int -> Expression a -> Doc Source #

Pretty print an expression

ppOp :: InfixOp a -> Doc Source #

Pretty print an operator

ppStmt :: Statement a -> Doc Source #

Pretty print a statement

ppFieldExpr :: Field (Expression a) -> Doc Source #

Pretty print a record field expression (Haskell syntax)

ppQualTypeExpr :: QualTypeExpr -> Doc Source #

Pretty print a qualified type expression

ppTypeExpr :: Int -> TypeExpr -> Doc Source #

Pretty print a type expression

ppAlt :: Alt a -> Doc Source #

Pretty print an alternative in a case expression