openvm_circuit_primitives::utils

Function select

Source
pub fn select<F: AbstractField>(
    cond: impl Into<F>,
    a: impl Into<F>,
    b: impl Into<F>,
) -> F
Expand description

Assumes that cond is boolean. Returns a if cond is true, otherwise returns b.