Commit Graph

1156 Commits

Author SHA1 Message Date
Alain
cfcc454022 feat: initial nix support 2021-10-29 14:45:05 +02:00
Denis Merigoux
2c0e8a7864
x10 performance on Catala compilation & interpretation
Cleaner rewriting of main let-binding chaining procedure from Scopelang to Dcalc
Removed costly unboxing in DCalc.Ast.make_let_in seemed to do the trick
2021-10-28 15:24:39 +02:00
Denis Merigoux
a271d96b3a
Remove glitch in HTML literate output 2021-10-25 10:12:42 +02:00
Denis Merigoux
cf31da7ca1
Remove limitation on Zarith since https://github.com/janestreet/zarith_stubs_js/pull/8 is closed 2021-10-18 09:58:47 +02:00
Denis Merigoux
8dbf034efc
Update generated assets 2021-10-11 17:41:20 +02:00
Denis Merigoux
6084b9acb3
Merge pull request #154 from edwintorok/spelling
Fix spelling and outdated syntax reference in tutorial_en
2021-10-11 17:27:15 +02:00
Denis Merigoux
3d9c125ce5
More doc 2021-10-11 14:55:50 +02:00
Denis Merigoux
1b1625bc1e
Fix French spelling 2021-10-11 14:40:44 +02:00
Edwin Török
c454c0531a examples/tutorial_en: be explicit about @ and ^ symbols
Use both their verbose name and symbols to make it obvious what they
refer to.

Signed-off-by: Edwin Török <edwin@etorok.net>
2021-10-10 16:05:00 +01:00
Edwin Török
ee03af4afc examples/tutorial_en: headers are prefixed with # not @
Since a42d0c7728 # is used.

Signed-off-by: Edwin Török <edwin@etorok.net>
2021-10-10 16:03:56 +01:00
Edwin Török
c201fee6b8 examples/tutorial_en: fix spelling
paragrah -> paragraph
analyse -> analyze
formulae -> formulas
substraction -> subtraction
adresses -> addresses
mentionned -> mentioned
conditionnally -> conditionally
explicitely -> explicitly
datatypes -> data types

Signed-off-by: Edwin Török <edwin@etorok.net>
2021-10-10 15:56:07 +01:00
Edwin Török
3eddaae882 examples: add a %.spellok helper to check spelling
Usage:
`make -C examples/tutorial_en tutorial_en.spellok`

This will output a list of incorrect words (which should be empty).
Catala-specific words (or uncommon words missing from the default aspell dictionary) can be added to examples/whitelist.<lang>

Signed-off-by: Edwin Török <edwin@etorok.net>
2021-10-10 15:56:07 +01:00
Denis Merigoux
5000417279
Update syntax reference 2021-10-01 16:31:50 +02:00
Denis Merigoux
65fa4b3c58
Merge pull request #150 from EmileRolley/refactor-metadata-markup
Refactor: new metadata markup, fixes #150
2021-10-01 16:28:36 +02:00
EmileRolley
50901fbb0c refactor(syntax-highlighting): support the new catala-metadata markup 2021-10-01 15:52:45 +02:00
Emile Rolley
9aaa614410 refactor(parser): add the new catala-metadata markup 2021-10-01 10:01:25 +02:00
Denis Merigoux
8c7d538cfb
Merge pull request #146 from CatalaLang/jemsab_4b
add legislative text (new version from #68)
2021-09-28 12:11:26 +02:00
Denis Merigoux
b72d8e09ee
Restore typechecking version of CGI example 2021-09-28 12:01:08 +02:00
Denis Merigoux
caf42f3445
Merge branch 'master' into jemsab_4b 2021-09-28 11:52:09 +02:00
Denis Merigoux
4019fa2b3e
Merge pull request #142 from govlab-org/feature/dockerfile
Add a Dockerfile for builds
2021-09-27 21:18:10 +02:00
Jean-Marc Le Roux
40180df85d Document how to build using Docker 2021-09-27 21:06:14 +02:00
Jean-Marc Le Roux
f05b8df50f Add a Dockerfile for builds 2021-09-23 17:08:52 +02:00
Denis Merigoux
0021c2c8e6
Merge pull request #139 from AltGr/fact-lexers
Factorise lexer translations
2021-08-23 14:36:49 +02:00
Denis Merigoux
577bfe67a5
Added dependencies at other places 2021-08-23 14:24:39 +02:00
Louis Gesbert
dc026d0a7f I was still unhappy with the remaining duplication
that and the double-matching with different kinds of regexps; it should be more
robust now.
2021-08-20 14:23:10 +02:00
Louis Gesbert
e7ad186bd7 Document adding new languages 2021-08-20 12:26:45 +02:00
Louis Gesbert
dfb358993c Small fix 2021-08-19 20:41:34 +02:00
Louis Gesbert
98aed4187a Further factorise decimals parsing 2021-08-19 20:32:23 +02:00
Louis Gesbert
47526bb4bd Update the 'add builtin' doc 2021-08-19 18:33:24 +02:00
Louis Gesbert
e431e194de Factorise lexer translations 2021-08-19 18:26:06 +02:00
Denis Merigoux
7cbb4a9149
Merge pull request #138 from AltGr/lexer-refactor
Cleanup the lexer, and refactor for more generic directives
2021-08-19 12:12:53 +02:00
Denis Merigoux
b56299f3d3
Switch ocamlformat to 0.19.0 2021-08-19 11:35:56 +02:00
Denis Merigoux
47e79de6a7 Display backtrace in CI 2021-08-19 11:26:48 +02:00
Louis Gesbert
fdcdefd4d0 Fix parser conflict
`LAW_TEXT` tokens are now returned one per line, so we need an associativity
rule to correctly aggregate them.
2021-08-19 11:25:32 +02:00
Louis Gesbert
9cb3a405d8 Fix lexing of money tokens
- The polish lexer was wrongly adapted from the american one: the code to trim
  the prefix `$` char was kept instead of trimming the postfix `PLN`
- Anyway the regex isn't enforced to match until the end of input so trimming
  postfix units is not needed
- And the trimming for `€` was wrong anyway, it assumed `€` is only 1 char long
  in utf8
2021-08-19 11:25:32 +02:00
Denis Merigoux
7817e9a855 Add odoc to dependencies 2021-08-19 11:25:32 +02:00
Louis Gesbert
3b5c4c17cd Resync the three lexers
We'll need to factorise that better in the not-too-far future: there was already
a discrepancy between en and fr; and this won't scale if we keep adding
languages.
2021-08-19 11:25:32 +02:00
Louis Gesbert
b31bee71ad Cleanup the lexer, and refactor for more generic directives 2021-08-18 18:23:08 +02:00
Denis Merigoux
0659816782
Fix indentation 2021-07-15 14:56:51 +02:00
Denis Merigoux
d8b18c80b8
Fixed syntax cheat sheet for extremum 2021-07-15 14:55:32 +02:00
Denis Merigoux
a9b84d2a1e
Merge pull request #137 from EmileRolley/feat-list-concat
Feat #109: add collection concatenation operator
2021-07-09 22:29:04 +02:00
EmileRolley
923a90b883 syntax(compiler): remove an @EmileRolley's note 2021-07-09 19:44:55 +02:00
EmileRolley
390149c19d fix: remove an unwanted pushed file 2021-07-09 19:43:02 +02:00
EmileRolley
ac47d1ff1a refactor(compiler): minor factorization of formatting functions inside the To_ocaml module 2021-07-08 17:00:24 +02:00
EmileRolley
731513a003 refactor(compiler): factorize formatters inside prints modules 2021-07-08 16:36:53 +02:00
EmileRolley
6169d19b1e feat(compiler): add collection concatenation operator 2021-07-08 16:27:46 +02:00
Denis Merigoux
9ef637a161
Print lists better 2021-06-26 18:13:13 +02:00
Denis Merigoux
0d54b39aa9
Logging in Python OK 2021-06-26 18:04:36 +02:00
Denis Merigoux
32c2e84a10
Improve Python library API 2021-06-26 17:12:15 +02:00
Denis Merigoux
61b84ed71b
Typo in README 2021-06-25 15:35:16 +02:00