 | haskell-src-exts-1.3.5: Manipulating Haskell source: abstract syntax, lexer, parser, and pretty-printer | Source code | Contents | Index |
|
Language.Haskell.Exts.Annotated.Build | |
|
|
|
|
Description |
This module contains combinators to use when building
Haskell source trees programmatically, as opposed to
parsing them from a string. The contents here are quite
experimental and will likely receive a lot of attention
when the rest has stabilised.
|
|
Synopsis |
|
|
|
|
Syntax building functions
|
|
|
An identifier with the given string as its name.
The string should be a valid Haskell identifier.
|
|
|
A symbol identifier. The string should be a valid
Haskell symbol identifier.
|
|
|
A local variable as expression.
|
|
|
Use the given identifier as an operator.
|
|
|
A qualified variable as expression.
|
|
|
A pattern variable.
|
|
|
Application of expressions by juxtaposition.
|
|
|
Apply an operator infix.
|
|
|
Apply a function to a list of arguments.
|
|
|
A constructor pattern, with argument patterns.
|
|
|
A tuple expression.
|
|
|
A tuple pattern.
|
|
|
A tuple expression consisting of variables only.
|
|
|
A tuple pattern consisting of variables only.
|
|
|
A function with a given name.
|
|
|
A literal string expression.
|
|
|
A literal character expression.
|
|
|
A literal integer expression.
|
|
|
A literal string pattern.
|
|
|
A literal character pattern.
|
|
|
A literal integer pattern.
|
|
|
A do block formed by the given statements.
The last statement in the list should be
a Qualifier expression.
|
|
|
Lambda abstraction, given a list of argument
patterns and an expression body.
|
|
|
A let ... in block.
|
|
|
A case expression.
|
|
|
An unguarded alternative in a case expression.
|
|
|
An alternative with a single guard in a case expression.
|
|
|
A list expression.
|
|
|
The empty list expression.
|
|
|
The empty list pattern.
|
|
|
Put parentheses around an expression.
|
|
|
Put parentheses around a pattern.
|
|
|
A qualifier expression statement.
|
|
|
A generator statement: pat <- exp
|
|
|
A let binding group as a statement.
|
|
|
Hoist a set of declarations to a binding group.
|
|
|
An empty binding group.
|
|
|
The wildcard pattern: _
|
|
|
Generate k names by appending numbers 1 through k to a given string.
|
|
More advanced building
|
|
|
A function with a single clause
|
|
|
A function with a single clause, a single argument, no guards
and no where declarations
|
|
|
A pattern bind where the pattern is a variable, and where
there are no guards and no 'where' clause.
|
|
|
A pattern bind where the pattern is a variable, and where
there are no guards, but with a 'where' clause.
|
|
|
Bind an identifier to an expression.
|
|
|
Apply function of a given name to a list of arguments.
|
|
|
Apply a constructor of a given name to a list of pattern
arguments, forming a constructor pattern.
|
|
Produced by Haddock version 2.6.0 |