Pantagruel v0.0.3 Pantagruel.Eval.Lambda View Source

A function in an evaluated Pantagruel program, either as introduced in a header declaration or referred to as an anonymous function inside of a section body.

The type of a lambda is either :function, which is a normal function from 0 or more arguments with an optional return type, or :constructor, which defines the construction function for complex types such as List[Int] or of objects with named fields.

The evaluation behavior of constructors is such that they also bind their codomain into scope; functions must have their codomains defined elsewhere.

Link to this section Summary

Functions

Bind a lambda form into scope

Given a function declaration, build a Lambda struct

Link to this section Functions

Bind a lambda form into scope.

Link to this function from_declaration(decl, doms \\ nil) View Source

Given a function declaration, build a Lambda struct.