Skip to content

Commit

Permalink
♻️ Ocaml
Browse files Browse the repository at this point in the history
  • Loading branch information
yhs0602 committed Jun 1, 2024
1 parent f0e8c83 commit 19426d9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/compile.ml
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,10 @@ let rec compile (env : Env.t) (pred : Pred.t) (exp : Exp.t) :
let g', de = compile env pred e in
(g @+ g', de))
in
let body = f.body in
let param_det_pairs = List.zip_exn f.params det_exps in
let { params; body; _ } = f in
let param_det_pairs = List.zip_exn params det_exps in
let sub_body =
List.fold_left param_det_pairs ~init:body
List.fold param_det_pairs ~init:body
~f:(fun acc (param_name, det_exp) -> sub acc param_name det_exp)
in
let g_body, det_exp_body = compile env pred sub_body in
Expand Down

0 comments on commit 19426d9

Please sign in to comment.