package catala
Compiler and library for the literate programming language for tax code specification
Install
Dune Dependency
Authors
Maintainers
Sources
0.5.0.tar.gz
md5=41b0317af37925b16ae7aedfddbcc8b4
sha512=f02c4e4c7d8ca92c4c2100d1dfc31c56218a8fae3760135335c9cdd10d9edbeb6eb5e407b430c095f579ce2226c3fe4c314788af5aa35c37d04e4dee5f459cb8
doc/index.html
The Catala compiler
Architecture
The architecture of the Catala compiler is inspired by CompCert or the Nanopass framework, and is structured around many intermediate representations connected by successive translations passes.
Here is the recap picture of the different intermediate representations of the Catala compiler (made with an ASCII diagram tool):
+---------------+ | | | Surface AST | | | +---------------+ | | * Separate code from legislation | * Remove syntactic sugars | v +---------------+ | | | Desugared AST | | | +---------------+ | | * Build rule trees for each definition | * Order variable computations inside scope | v +--------------------+ | | | Scope language AST | | | +--------------------+ | | * Convert scopes into functions | * Thunking of subscope arguments | | v +----------------------+ | | | Default calculus AST | | | +----------------------+ | | | * Compile the default term | | v +----------------------+ | | | Lambda calculus AST | | | +----------------------+
List of top-level modules
Each of those intermediate representation is bundled into its own `dune` bundle module. Click on the items below if you want to dive straight into the signatures.
More documentation can be found on each intermediate representations here.
- The surface representation
- The desugared representation
- The scope language
- The default calculus
- The lambda calculus
The main compilation chain is defined in:
Last, two more modules contain additional features for the compiler:
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
On This Page