174 Commits

Author SHA1 Message Date
Gabriel Scherer
45e1f17227 clarify the visibility of environment items
Before doing this change, I had no clue what those (cons # ...) would mean,
2020-12-07 11:25:08 +01:00
Gabriel Scherer
7a14982cc2 [minor] pattern-matching in vhash-{map,filter-map} 2020-12-07 11:25:08 +01:00
Gabriel Scherer
0b197cb705
Merge pull request #15 from Ekdohibs/ocamllex
Ocamllex
2020-12-05 16:51:37 +01:00
Julien Lepiller
de8c561c40 Ignore generated interpreter files 2020-12-05 15:33:44 +01:00
Julien Lepiller
eb98434c9f lexer: lex_string: Use buffer directly. 2020-12-05 14:58:08 +01:00
Julien Lepiller
c195c3b83e lexer: try_skip_space_and_comments: Make tail-recursive. 2020-12-05 14:58:04 +01:00
Julien Lepiller
7ff2fb4f6c lexer: Use Char.code '0' instead of magic constant 2020-12-05 14:57:44 +01:00
Julien Lepiller
55d5bce3ae interp: Add missing end 2020-12-05 13:38:40 +01:00
Gabriel Scherer
da11c946dc fix IRebind compilation 2020-12-05 07:21:11 +01:00
Nathanaël Courant
bc1487b12c Add definition for infix :: constructor 2020-12-04 15:15:50 +01:00
Nathanaël Courant
603090e8c3 Use the new infix operators instead of fixed names 2020-12-04 15:15:50 +01:00
Nathanaël Courant
2e0d235ce3 Fix the other conflict 2020-12-04 15:15:50 +01:00
Nathanaël Courant
654f8a7989 Fix lident_ext 2020-12-04 15:15:50 +01:00
Nathanaël Courant
cbfa7ff6a0 Fix conflict with infix operators 2020-12-04 15:15:50 +01:00
Nathanaël Courant
95da29da2f Record construction must use longident_field... but more conflicts 2020-12-04 15:15:50 +01:00
Nathanaël Courant
a037d4071d Initial try for infix operators 2020-12-04 15:15:50 +01:00
Nathanaël Courant
e783d2c8c0 Fix shape of let ... = function at toplevel 2020-12-03 22:27:21 +01:00
Julien Lepiller
a6990cc1fb Add ocamllex bootstrap lexer 2020-12-03 20:00:53 +01:00
Nathanaël Courant
ff6db2bb00 Fix interpreter genfile 2020-12-02 15:15:49 +01:00
Gabriel Scherer
1357bf2c78 compile.scm: lower Lambda 2020-12-02 10:09:23 +01:00
Gabriel Scherer
738c69092a compile.scm: lower Let 2020-12-02 10:09:23 +01:00
Gabriel Scherer
1fe521ea06 compile.scm: lower Match and Try into Switch and Catch 2020-12-02 10:09:23 +01:00
Gabriel Scherer
99173f7233 compile.scm: helper functions for variable and constructor desugaring 2020-12-02 10:09:23 +01:00
Gabriel Scherer
363f2047b7 compile.scm: lower EApply 2020-12-02 10:09:23 +01:00
Gabriel Scherer
88623f4f02 compile.scm: lower Getfield, Setfield 2020-12-02 10:09:23 +01:00
Gabriel Scherer
518ec3aa6d compile.scm: lower ERecordwith 2020-12-02 10:09:23 +01:00
Gabriel Scherer
2875adb603 compile.scm: lower ERecord 2020-12-02 10:09:23 +01:00
Gabriel Scherer
a32b5a4f4b compile.scm: lower constructors 2020-12-02 10:09:23 +01:00
Gabriel Scherer
a86494145b compile.scm: lower constants 2020-12-02 10:09:23 +01:00
Gabriel Scherer
1202e82461 compile.scm: introduce a (currently-empty) distinction between 'lowering' and code production 2020-12-02 10:09:23 +01:00
Gabriel Scherer
9b27099bab factorize vhash-replace calls on the environment 2020-12-01 12:51:00 +01:00
Gabriel Scherer
61f8c29e12 compile.scm: minor refactor 2020-12-01 12:49:32 +01:00
Gabriel Scherer
8604066454 compile.scm: match in compile-def 2020-12-01 12:10:30 +01:00
Gabriel Scherer
3b640bb5bc compile.scm: match in compile-type 2020-12-01 12:10:30 +01:00
Gabriel Scherer
f51a735e6a compile.scm: refactor get-fun-body 2020-12-01 12:10:00 +01:00
Gabriel Scherer
470c006660 [minor] cut some long lines 2020-12-01 12:07:11 +01:00
Nathanaël Courant
729a7c524d Add recursive closures 2020-12-01 11:38:18 +01:00
Nathanaël Courant
85fb44073c Add command arguments to compile.scm 2020-12-01 09:02:13 +01:00
Nathanaël Courant
68532527cf Handle externally raised exceptions 2020-11-30 21:32:14 +01:00
Gabriel Scherer
09979f89cb compile.scm: match in expr-fv 2020-11-30 21:29:01 +01:00
Gabriel Scherer
719dbf9973 compile.scm: record for function arguments 2020-11-30 21:29:01 +01:00
Gabriel Scherer
94adbfe3b7 compile.scm: record for definitions 2020-11-30 21:29:01 +01:00
Gabriel Scherer
7b4984e1d8 compile.scm: match in compile-expr 2020-11-30 21:29:01 +01:00
Gabriel Scherer
7e4e53dd3d compile.scm: records for switch clauses 2020-11-30 21:29:01 +01:00
Gabriel Scherer
1744db1ffe compile.scm: records for switch consts and blocks 2020-11-30 21:29:01 +01:00
Gabriel Scherer
a767fee54c compile.scm: match 2020-11-30 21:29:01 +01:00
Gabriel Scherer
b162b7f1dc compile.scm: match 2020-11-30 21:29:01 +01:00
Gabriel Scherer
18b1de0ba3 compile.scm: add records 2020-11-30 21:29:01 +01:00
Gabriel Scherer
1523ea9454 compile.scm: add match 2020-11-30 21:29:01 +01:00
Nathanaël Courant
4ee49920e1 Delete old miniml interpreter 2020-11-30 17:05:17 +01:00