Browse Source

'cargo fmt'

master
Nirvan Tyagi 4 years ago
committed by Pratyush Mishra
parent
commit
45a4c3b326
1 changed files with 9 additions and 9 deletions
  1. +9
    -9
      src/bits/uint8.rs

+ 9
- 9
src/bits/uint8.rs

@ -297,13 +297,13 @@ impl CondSelectGadget for UInt8 {
.zip(&false_value.bits)
.map(|(t, f)| cond.select(t, f))
.collect::<Result<Vec<_>, SynthesisError>>()?;
let selected_value = cond.value().ok().and_then(|cond| {
if cond {
true_value.value().ok()
} else {
false_value.value().ok()
}
});
let selected_value = cond.value().ok().and_then(|cond| {
if cond {
true_value.value().ok()
} else {
false_value.value().ok()
}
});
Ok(Self {
bits: selected_bits,
value: selected_value,
@ -401,8 +401,8 @@ mod test {
for x in v.iter().zip(expected_to_be_same.iter()) {
match x {
(&Boolean::Constant(true), &Boolean::Constant(true)) => {}
(&Boolean::Constant(false), &Boolean::Constant(false)) => {}
(&Boolean::Constant(true), &Boolean::Constant(true)) => {},
(&Boolean::Constant(false), &Boolean::Constant(false)) => {},
_ => unreachable!(),
}
}

Loading…
Cancel
Save