mirror of
https://github.com/CatalaLang/catala.git
synced 2024-11-08 07:51:43 +03:00
Update syntax guide recommendation
This commit is contained in:
parent
144046b9c5
commit
8ab7362793
@ -99,6 +99,7 @@ Using another version may cause spurious diffs to appear in your pull requests.
|
|||||||
The language provides a limited number of builtin functions, which are sometimes
|
The language provides a limited number of builtin functions, which are sometimes
|
||||||
needed for things that can't easily be expressed in Catala itself; in case you
|
needed for things that can't easily be expressed in Catala itself; in case you
|
||||||
need more, here is how one can be added:
|
need more, here is how one can be added:
|
||||||
|
|
||||||
- Choose a name wisely. Be ready to patch any code that already used the name
|
- Choose a name wisely. Be ready to patch any code that already used the name
|
||||||
for scope parameters, variables or structure fields, since it won't compile
|
for scope parameters, variables or structure fields, since it won't compile
|
||||||
anymore.
|
anymore.
|
||||||
@ -112,8 +113,9 @@ need more, here is how one can be added:
|
|||||||
- Extend the printer (`dcalc/print.ml`) and the typer with correct type
|
- Extend the printer (`dcalc/print.ml`) and the typer with correct type
|
||||||
information (`dcalc/typing.ml`)
|
information (`dcalc/typing.ml`)
|
||||||
- Finally, provide the implementations:
|
- Finally, provide the implementations:
|
||||||
* in `lcalc/to_ocaml.ml`, function `format_unop`
|
- in `lcalc/to_ocaml.ml`, function `format_unop`
|
||||||
* in `dcalc/interpreter.ml`, function `evaluate_operator`
|
- in `dcalc/interpreter.ml`, function `evaluate_operator`
|
||||||
|
- Update the syntax guide in `doc/syntax/syntax.tex` with your new builtin
|
||||||
|
|
||||||
## Internationalization
|
## Internationalization
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user