Stability | experimental |
---|---|
Safe Haskell | None |
Language | Haskell2010 |
A pretty printer for Egison patterns.
Synopsis
- prettyExpr :: (MonadError (Error n) m, Ord n) => PrintMode n v e -> Expr n v e -> m Text
- newtype Error n = UnknownInfixOperator n
- data Associativity
- newtype Precedence = Precedence Int
- data Fixity n = Fixity {
- associativity :: Associativity
- precedence :: Precedence
- symbol :: n
- data PrintMode n v e = PrintMode {
- fixities :: [PrintFixity n]
- varNamePrinter :: ExtPrinter v
- namePrinter :: ExtPrinter n
- valueExprPrinter :: ExtPrinter e
- pageMode :: Maybe PageMode
- data PageMode = PageMode {}
- data PrintFixity n = PrintFixity {}
- type ExtPrinter a = a -> Text
Documentation
prettyExpr :: (MonadError (Error n) m, Ord n) => PrintMode n v e -> Expr n v e -> m Text Source #
Pretty print Expr
.
Re-exports
data Associativity Source #
Associativity of infix operators.
Instances
newtype Precedence Source #
A precedence of infix operators.
Instances
Fixity of infix operators.
Fixity | |
|
Printer configuration.
PrintMode | |
|
Rendering style configuration.
type ExtPrinter a = a -> Text Source #
is a type for externally provided printer of ExtPrinter
aa
.