Louis Gesbert
86b7f80e90
Clerk improvements
...
- Add a `-I` option that allows defined modules to be available from other
directories
- Add reporting of the number of successful / failed tests
- Locate the project root, and always run the commands from there
2023-11-30 21:14:12 +01:00
Louis Gesbert
c019d1568f
Clerk: fix handling of dependency on the catala exec
2023-11-30 17:46:38 +01:00
Louis Gesbert
d4198f52b4
Reformat
2023-11-28 17:22:46 +01:00
Louis Gesbert
f3dd1c06d0
Interpreter: handle lcalc with exceptions ( #533 )
2023-11-28 15:43:29 +01:00
Louis Gesbert
d256cf5eec
Update minimum OCaml version
2023-11-28 15:41:27 +01:00
Louis Gesbert
5b5790b95b
Fix compilation of the clerk opam package
2023-11-28 15:33:30 +01:00
Louis Gesbert
326ee07f5d
Interpreter: handle lcalc with exceptions
2023-11-28 15:02:11 +01:00
Louis Gesbert
1b02a672fa
Internally type default terms in the compiler ( #528 )
2023-11-28 13:51:42 +01:00
Louis Gesbert
4e465d2b48
Printer: some small improvements
2023-11-28 13:37:46 +01:00
Louis Gesbert
447f6d41f1
Interpreter: fix execution with closure_conversion
...
and context variables
2023-11-28 13:37:46 +01:00
Louis Gesbert
645c263ccc
Fix closure-conversion
...
Joint debugging with @denismerigoux :)
2023-11-28 11:18:41 +01:00
Louis Gesbert
80475ad5ef
Printer: show toplevel uids in debug mode
...
otherwise we had an inconsistency between what's defined at toplevel and what
appears in expressions.
2023-11-28 11:15:01 +01:00
Louis Gesbert
f0d930688e
Support closure conversion with disabled typing or optims
...
This is very useful for debugging
2023-11-28 11:14:48 +01:00
Louis Gesbert
cf89204a4b
Reformat
2023-11-27 11:17:38 +01:00
Louis Gesbert
35b40785c7
Update tests (lcalc+avoid_exceptions outputs changed)
2023-11-27 11:17:38 +01:00
adelaett
8a85e7b78f
typing defaults: update passing tests
2023-11-27 11:17:38 +01:00
adelaett
a734413d39
typing default: fix ocaml runtime when using eoption
2023-11-27 11:17:38 +01:00
adelaett
f254906952
typing defaults: update passing tests
2023-11-27 11:17:38 +01:00
adelaett
ae4956c40f
Typing defaults: update ocaml & python runtimes.
2023-11-27 11:17:38 +01:00
adelaett
dda09f0cc1
typed defaults: update passing tests.
2023-11-27 11:17:34 +01:00
adelaett
324ca74053
typed defaults: fixed interpreter value initialization in lcalc mode
...
when having the avoid_exceptions flag enabled.
2023-11-27 11:12:35 +01:00
adelaett
576da177c5
Typed defaults: translate types in scope lets as well in the new
...
compile without exception passe
2023-11-27 11:12:35 +01:00
adelaett
f6027109d8
Typed default: Update passing tests
...
For now, most tests involving only one scope and no context do pass.
More work is required for the rest.
2023-11-27 11:12:26 +01:00
adelaett
cb29fdeefe
fixing the handle_opt in the interpreter.
2023-11-27 11:09:08 +01:00
adelaett
1d72a57da4
Typed default: fix an issue to the error_on_empty constructor
2023-11-27 11:09:08 +01:00
adelaett
4a5335162e
Typed default: implementing the type for handle defaults, as well as the
...
compile without exceptions compilation pass, using the newly found
invariant
2023-11-27 11:09:08 +01:00
adelaett
b0b83b14b9
Typed default: Implemented typing translating to the without exception compilation path.
2023-11-27 11:09:08 +01:00
adelaett
2c9f8ad8b1
Typed default: import the code from compile with exceptions to
...
re-implement without exceptions with the new typing of defaults terms.
2023-11-27 11:09:08 +01:00
Louis Gesbert
fca3221b78
Ensure dune exec -- clerk ...
runs an up-to-date catala exec
2023-11-27 11:09:08 +01:00
Louis Gesbert
cc4e5339dd
Typed defaults: small simplification and fixes
2023-11-27 11:09:08 +01:00
Louis Gesbert
3a149bc86e
Fix compilation of plugins
2023-11-27 11:09:08 +01:00
Louis Gesbert
1efda5ca22
Typing defaults: support nested priorities
...
The way nested priorities are encoded use `< < excs | true :- nested > :- x >`,
which imply that `nested` can actually be ∅ ; to cope with this, the typing of
default terms is made more generic (the return type is now the same as the
`cons` type `'a`, rather than `<'a>`). For the general case, we add an explicit
`EPureDefault` node which just encapsulates its argument (a `return`, in monad
terminology).
2023-11-27 11:09:08 +01:00
Louis Gesbert
4ececf9960
Fix api_web plugin
2023-11-27 11:09:08 +01:00
Louis Gesbert
c4715ea86e
Reformat
2023-11-27 11:09:08 +01:00
Louis Gesbert
bcf285913e
Typing the HandleDefault operator
2023-11-27 11:06:33 +01:00
Louis Gesbert
fd50e6186f
Fix default typing across modules
2023-11-27 11:06:33 +01:00
Louis Gesbert
9203e4f7bb
Verification: support unboxed defaults
2023-11-27 11:06:33 +01:00
Louis Gesbert
dc3ffa0dcd
Fix some error handling on scope calls
...
(and add suggestions)
2023-11-27 11:06:33 +01:00
Louis Gesbert
d00cac09ad
Harmless test results changes
2023-11-27 11:06:33 +01:00
Louis Gesbert
958aaebac3
Typing defaults fixes: keep in and out type in scope sigs
2023-11-27 11:06:16 +01:00
Louis Gesbert
ab6bec390d
Adjust plugins and warnings
2023-11-27 11:06:16 +01:00
Louis Gesbert
0be2636e65
Typing defaults: making the compiler adhere to the new type discipline
2023-11-27 11:06:01 +01:00
Louis Gesbert
52486af6ac
Correct typing of context subscope variables
2023-11-27 11:06:01 +01:00
Louis Gesbert
b98bad8c33
Add a --no-typing option
...
it is useful e.g. to be able to print intermediate ASTs when they don't type, to
debug the typing errors. This is better than commenting the typing line each
time.
Note that the option is not available on all targets (esp. not for ocaml and
python outputs ; it's allowed on the interpreters for debugging purposes but I'm
not sure if that's a good idea)
2023-11-27 11:06:01 +01:00
Louis Gesbert
9425753eca
Typer: add built-in "'a default" type
2023-11-27 11:06:01 +01:00
Louis Gesbert
e2730c0b44
Avoid redundant position in type error
2023-11-27 11:05:58 +01:00
Louis Gesbert
4fa9326618
Typer: on error, print the expression being typed in debug mode
...
useful when typing fails on internally generated expressions
2023-11-27 11:03:47 +01:00
Denis Merigoux
63f0cad312
Debug French housing benefits by comparing to the CAF API ( #531 )
2023-11-24 16:52:29 +01:00
Denis Merigoux
2b89e530b0
Code refactoring that works at execution + mypy
2023-11-23 15:38:45 +01:00
Denis Merigoux
fb85c64cfa
Continue debugging
2023-11-23 11:54:54 +01:00