This commit is contained in:
Mylloon 2023-12-15 19:15:54 +01:00
parent 939d015453
commit ebd9544870
Signed by: Anri
GPG key ID: A82D63DFF8D1317F

View file

@ -239,8 +239,7 @@ let translate (p : S.t) env =
let fname = make_fresh_function_identifier () in
let x = List.map identifier x in
let efs, e = expression env e in
failwith "Students! This is your job (S.Fun)!"
(* efs, T.DefineFunction (fname, x, e) *)
T.DefineFunction (fname, x, e) :: efs, e
| S.AllocateBlock a ->
let afs, a = expression env a in
afs, allocate_block a