std.syntax.typed_lambda.named¶
Author closed intrinsically typed lambda terms with named binders. A declaration splice resolves binders to the typed term constructors declared by the caller. The generated declaration is checked normally.
The examples on this page run in this module, which opens std.syntax.typed_lambda.named:
define_named (computation)¶
meta define define_named(declaration : SynDecl) : SynDecl !{refusal}
Splice a nullary definition returning a closed lambda term. Write
p -> p("Jo") for an abstraction whose body applies p to the typed
constant "Jo". Declare the result as Term(Empty, t) or as a local
indexed carrier over the same type indices. The caller provides the
term constructors, for instance with std.syntax.typed_lambda.derive.
A single outer constructor
can embed the term in that carrier, as in Pure(p -> p("Jo")).