Skip to content
This repository has been archived by the owner on May 7, 2024. It is now read-only.

Commit

Permalink
fix: fix branch signature
Browse files Browse the repository at this point in the history
  • Loading branch information
lm98 committed Oct 11, 2023
1 parent 360d29b commit 7059bcf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/core/lang/lang.rs
Original file line number Diff line number Diff line change
Expand Up @@ -137,10 +137,11 @@ fn nbrs_computation<A: Copy + 'static>(vm: RoundVM, expr: impl Fn(RoundVM) -> (R
/// # Returns
///
/// the value of the expression
pub fn branch<A: Copy + 'static, B, F>(mut vm: RoundVM, cond: B, thn: F, els: F) -> (RoundVM, A)
pub fn branch<A: Copy + 'static, B, TH, EL>(mut vm: RoundVM, cond: B, thn: TH, els: EL) -> (RoundVM, A)
where
B: Fn() -> bool,
F: Fn(RoundVM) -> (RoundVM, A),
TH: Fn(RoundVM) -> (RoundVM, A),
EL: Fn(RoundVM) -> (RoundVM, A),
{
vm.nest_in(Branch(vm.index().clone()));
let (vm, tag) = locally(vm, |_vm1| (_vm1, cond()));
Expand Down

0 comments on commit 7059bcf

Please sign in to comment.