catala/compiler/lcalc/lcalc.mld

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

43 lines
1.4 KiB
Plaintext
Raw Normal View History

2021-03-19 19:49:56 +03:00
{0 Lambda calculus}
This representation is the fifth in the compilation chain
(see {{: index.html#architecture} Architecture}). Its main difference
2023-06-02 18:17:45 +03:00
with the previous {{: dcalc.html} default calculus} is the absence of the
2021-03-19 19:49:56 +03:00
default term, which has been eliminated through diverse compilation schemes.
The module describing the abstract syntax tree is:
2023-06-02 18:17:45 +03:00
{!modules: Lcalc.Ast}
2021-03-19 19:49:56 +03:00
This intermediate representation corresponds to the lambda calculus
presented in the {{: https://arxiv.org/abs/2103.03198} Catala formalization}.
{1 Compilation from default calculus }
{!module: Lcalc.Compile_with_exceptions} compiles the default term of the
default calculus using catchable exceptions. This compilation scheme has been
2023-06-02 18:17:45 +03:00
certified. Another compilation scheme that uses an option monad instead is
available at {!module:Lcalc.Compile_without_exceptions}.
2021-03-19 19:49:56 +03:00
Related modules:
2023-06-02 18:17:45 +03:00
{!modules: Lcalc.Compile_with_exceptions Lcalc.Compile_without_exceptions}
2022-01-19 12:54:16 +03:00
2023-06-18 17:08:16 +03:00
{1 Closure conversion }
To target languages that don't have support for closures, we need to convert
the closures to first-class functions in function-pointer-passing style
computations.
{!modules: Lcalc.Closure_conversion }
2022-01-19 12:54:16 +03:00
{1 Backends}
2021-03-19 19:49:56 +03:00
The OCaml backend of the lambda calculus is merely a syntactic formatting,
2021-06-21 19:00:06 +03:00
since the core of the OCaml value language is effectively a lambda calculus.
2022-01-19 12:54:16 +03:00
Related modules:
2023-06-02 18:17:45 +03:00
{!modules: Lcalc.To_ocaml}
2022-01-19 12:54:16 +03:00