Commit Graph

1127 Commits

Author SHA1 Message Date
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
Denis Merigoux
c0a47aa487
Merge pull request #135 from CatalaLang/python-backend
Python backend
2021-06-25 10:56:09 +02:00
Denis Merigoux
ae8ef08b81
Added more doc 2021-06-25 10:50:49 +02:00
Denis Merigoux
771bc83080
Added generated code as binary 2021-06-25 00:58:47 +02:00
Denis Merigoux
3d2f3497bc
Switch to benchmark 2021-06-25 00:56:08 +02:00
Denis Merigoux
03b44f5b15
Python backend debugged and tested 2021-06-25 00:47:12 +02:00
Denis Merigoux
e38dc4c728
Various bugfixing and improvements for the Python backend 2021-06-25 00:16:21 +02:00
Denis Merigoux
3f5027e5a5
Translation now typechecks 2021-06-24 22:55:27 +02:00
Denis Merigoux
95b34937a6
Switch to use Python enums as a tag for tagged unions 2021-06-24 21:55:20 +02:00
Denis Merigoux
fbf60b89bf
Fix lenght type mismatch 2021-06-24 21:32:09 +02:00
Denis Merigoux
b68b9b31a1
More sensible order for make all 2021-06-24 18:30:54 +02:00
Denis Merigoux
8b956bf4fa
Missing cd 2021-06-24 18:27:02 +02:00
Denis Merigoux
ccf2bba79f
Executable permission for env setup 2021-06-24 18:21:21 +02:00
Denis Merigoux
0481181f92
Put mypy typing under CI 2021-06-24 18:18:25 +02:00
Denis Merigoux
817b1785df
Python translation working but still buggy 2021-06-24 17:50:08 +02:00
Denis Merigoux
015776270d
Compilation passing from lcalc to scalc 2021-06-24 14:52:51 +02:00
Denis Merigoux
eb9c75f394
Making progress into translation 2021-06-23 17:47:34 +02:00
Denis Merigoux
46717b0440
Compiling blocks to SCalc 2021-06-22 18:16:47 +02:00
Denis Merigoux
1313183353
Defining a new intermediate representation 2021-06-22 16:01:57 +02:00
Denis Merigoux
fffd0ffb63
Working the way into the Python backend 2021-06-22 14:55:43 +02:00
Denis Merigoux
9ab32efcce
Added machinery for Python backend 2021-06-21 18:00:06 +02:00
Denis Merigoux
867126f8e4
Added module list for Python doc 2021-06-21 17:42:40 +02:00
Denis Merigoux
488baa9c5e
Wrap up runtime 2021-06-21 17:33:29 +02:00
Denis Merigoux
8c30e059a7
Add functions to runtime, doc setup 2021-06-21 16:51:02 +02:00
Denis Merigoux
db026c6720
Start to implement Python runtime 2021-06-21 12:31:46 +02:00