catala/compiler/surface
Louis Gesbert 4ae392c900 AST refactoring
Many changes got bundled in here and would be too tedious to separate.

Closes #330

See changes in `shared_ast/definitions.ml` to check the main point.

- the biggest change is a modification of the struct and enum types in
  expressions: they are now stored as `Map`s throughout passes, and no longer
  converted to indexed lists after scopelang. Their accessors are also changed,
  and tuples only exist in Lcalc (they're used for closure conversion).

  This implied adding some more information in the contexts, to keep the mapping
  between struct fields and scope output variables. It should also be much more
  robust (no longer relying on assumptions upon different orderings).

- another very pervasive change is more cosmetic: the rewrite of the main AST to
  use inline records, labelling individual subfields.

- moved the checks for correct definitions and accesses of structures from
  `Scope_to_dcalc` to `Typing`

- defining some new shallow iterators in module `Shared_ast.Expr`, and
  factorising a few same-pass rewriting functions accordingly (closure
  conversion, optimisations, etc.)

- some smaller style improvements (ensuring we use the proper compare/equal
  functions instead of `=` in a few `when` closes, for example)
2022-11-17 18:16:09 +01:00
..
.ocamlformat-ignore Workaround some ocamlformat crashes 2022-05-11 16:21:07 +02:00
ast.ml Make scopes directly callable 2022-10-21 17:17:26 +02:00
desugaring.ml AST refactoring 2022-11-17 18:16:09 +01:00
desugaring.mli Big reformatting 2022-03-08 15:03:14 +01:00
dune Merge branch 'master' into dates_calc_lib 2022-08-06 17:26:55 +02:00
fill_error_tokens.py Big renaming and dir reorg 2021-06-21 11:39:06 +02:00
fill_positions.ml Propagate renaming of Pos.mark* into module Marked 2022-07-11 16:51:54 +02:00
fill_positions.mli Big reformatting 2022-03-08 15:03:14 +01:00
lexer_common.ml Improvements to expiration checking 2022-09-07 17:14:22 +02:00
lexer_common.mli Fix doc generation 2022-04-14 11:18:26 +02:00
lexer_en.cppo.ml Add local 'let in' bindings 2022-08-09 12:17:31 +02:00
lexer_en.mli Big reformatting 2022-03-08 15:03:14 +01:00
lexer_fr.cppo.ml Add local 'let in' bindings 2022-08-09 12:17:31 +02:00
lexer_fr.mli Big reformatting 2022-03-08 15:03:14 +01:00
lexer_pl.cppo.ml Add local 'let in' bindings 2022-08-09 12:17:31 +02:00
lexer_pl.mli Big reformatting 2022-03-08 15:03:14 +01:00
lexer.cppo.ml Remove division durations 2022-08-19 15:21:29 +02:00
name_resolution.ml AST refactoring 2022-11-17 18:16:09 +01:00
name_resolution.mli AST refactoring 2022-11-17 18:16:09 +01:00
parse_utils.ml Big reformatting 2022-03-08 15:03:14 +01:00
parse_utils.mli Big reformatting 2022-03-08 15:03:14 +01:00
parser_driver.ml Propagate renaming of Pos.mark* into module Marked 2022-07-11 16:51:54 +02:00
parser_driver.mli Big reformatting 2022-03-08 15:03:14 +01:00
parser_errors.mli Big reformatting 2022-03-08 15:03:14 +01:00
parser.messages Make scopes directly callable 2022-10-21 17:17:26 +02:00
parser.mly Make scopes directly callable 2022-10-21 17:17:26 +02:00
print.ml Big reformatting 2022-03-08 15:03:14 +01:00
print.mli Big reformatting 2022-03-08 15:03:14 +01:00
surface.mld Documentation pass 2022-01-19 10:54:16 +01:00
tokens.mly Improvements to expiration checking 2022-09-07 17:14:22 +02:00