summaryrefslogtreecommitdiff
path: root/compiler
diff options
context:
space:
mode:
authorSon Ho2023-12-15 17:22:01 +0100
committerSon Ho2023-12-15 17:22:01 +0100
commit5fa83883b4d573cfd252478f7937c8bde0ec01f6 (patch)
treeb9812b7b8bed42a5cad466b7ce73b84c39f2fa7e /compiler
parentea583d9f0f5e4a1a687b70f0e04e875969462157 (diff)
Minor fix
Diffstat (limited to '')
-rw-r--r--compiler/SymbolicToPure.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/SymbolicToPure.ml b/compiler/SymbolicToPure.ml
index 8e06db7c..08f9e950 100644
--- a/compiler/SymbolicToPure.ml
+++ b/compiler/SymbolicToPure.ml
@@ -2605,10 +2605,11 @@ and translate_forward_end (ectx : C.eval_ctx)
assert (not !Config.return_back_funs);
let translate_one_end ctx (bid : RegionGroupId.id option) =
+ let ctx = { ctx with bid } in
(* Update the current state with the additional state received by the backward
function, if needs be, and lookup the proper expression *)
let ctx, e, finish =
- match ctx.bid with
+ match bid with
| None ->
(* We are translating the forward function - nothing to do *)
(ctx, fwd_e, fun e -> e)
@@ -2628,7 +2629,6 @@ and translate_forward_end (ectx : C.eval_ctx)
to introduce fresh variables for the additional inputs,
because they are locally introduced in a lambda *)
let back_sg = RegionGroupId.Map.find bid ctx.sg.back_sg in
- let ctx = { ctx with bid = Some bid } in
let ctx, backward_inputs_no_state =
fresh_vars back_sg.inputs_no_state ctx
in