From 939d015453d161820dec678627655d23a44c1815 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Fri, 15 Dec 2023 14:06:55 +0100 Subject: [PATCH] jpige r --- flap/src/fopix/hobixToFopix.ml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/flap/src/fopix/hobixToFopix.ml b/flap/src/fopix/hobixToFopix.ml index 799ef70..7d39d3b 100644 --- a/flap/src/fopix/hobixToFopix.ml +++ b/flap/src/fopix/hobixToFopix.ml @@ -235,7 +235,12 @@ let translate (p : S.t) env = let bfs, b = expression env b in let cfs, c = expression env c in afs @ bfs @ cfs, T.IfThenElse (a, b, c) - | S.Fun (x, e) -> failwith "Students! This is your job (S.Fun)!" + | S.Fun (x, e) -> + 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) *) | S.AllocateBlock a -> let afs, a = expression env a in afs, allocate_block a