catala/compiler
Louis Gesbert 371f9554b8 Support for list recombinations
The primary use-case for this was to be able to run computations on a list of
structures, then return an updated list with some fields in the structures
modified : that is what we need for distribution of tax amounts among household
members, for example.

This patch has a few components:

- Addition of a test as an example for tax distributions

- Added a transformation, performed during desugaring, that -- where lists are
  syntactically expected, i.e. after the `among` keyword -- turns a (syntactic)
  tuple of lists into a list of tuples ("zipping" the lists)

- Arg-extremum transformation was also fixed to use an intermediate list instead
  of computing the predicate twice

- For convenience, allow to bind multiple variables in most* list
  operations (previously only `let in` and functions allowed it)

- Fixed the printer for tuples to differentiate them from lists

*Note: tuples are not yet allowed on the left-hand side of filters and
arg-extremums for annoying syntax conflict reasons.
2024-01-26 11:29:33 +01:00
..
catala_utils Better version handling 2024-01-24 11:41:34 +01:00
dcalc Reduce default verbosity of invariant checks 2024-01-25 18:18:43 +01:00
desugared Support for list recombinations 2024-01-26 11:29:33 +01:00
lcalc Closure conversion: use multiple let-in 2023-12-19 17:30:32 +01:00
literate Fix #543 2023-12-06 16:58:38 +01:00
plugins AST change: more specific application 2023-12-19 17:27:40 +01:00
scalc Add (internally) a map2 operator 2024-01-26 11:22:12 +01:00
scopelang AST change: more specific application 2023-12-19 17:27:40 +01:00
shared_ast Support for list recombinations 2024-01-26 11:29:33 +01:00
surface Support for list recombinations 2024-01-26 11:29:33 +01:00
verification AST change: more specific application 2023-12-19 17:27:40 +01:00
catala_web_interpreter.ml Rework resolution of module elements 2023-11-30 21:14:12 +01:00
catala.ml replace let _ by let () or add type annotation 2023-09-09 22:02:39 +02:00
driver.ml Reduce default verbosity of invariant checks 2024-01-25 18:18:43 +01:00
driver.mli Reformat 2023-11-30 23:53:38 +01:00
dune CI: cleanup the exposed artifacts 2024-01-22 13:58:32 +01:00
index.mld More doc 2023-06-18 16:08:16 +02:00
plugin.ml Reformat 2023-09-27 13:19:04 +02:00
plugin.mli Refacter the main Driver module 2023-07-03 16:42:54 +02:00
tests.ml Fix running inline tests 2024-01-18 16:14:27 +01:00