From a3e1cd6cf2ac1b8770954649be49ae5217869b80 Mon Sep 17 00:00:00 2001 From: Pratyush Mishra Date: Sun, 19 Jan 2020 20:13:49 -0800 Subject: [PATCH] Make libraries compile --- r1cs-std/src/bits/boolean.rs | 7 ++++--- r1cs-std/src/groups/curves/short_weierstrass/mod.rs | 6 +++--- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/r1cs-std/src/bits/boolean.rs b/r1cs-std/src/bits/boolean.rs index 4dcde6a..37613f1 100644 --- a/r1cs-std/src/bits/boolean.rs +++ b/r1cs-std/src/bits/boolean.rs @@ -308,7 +308,7 @@ impl AllocGadget for AllocatedBit { } } -impl CondSelectGadget for AllocatedBit { +impl CondSelectGadget for AllocatedBit { fn conditionally_select>( cs: CS, cond: &Boolean, @@ -328,7 +328,7 @@ impl CondSelectGadget for AllocatedBit { } } -fn cond_select_helper>( +fn cond_select_helper>( mut cs: CS, cond: &Boolean, first: (Option, impl Into>), @@ -785,7 +785,8 @@ impl ToBytesGadget for Boolean { self.to_bytes(cs) } } -impl CondSelectGadget for Boolean { + +impl CondSelectGadget for Boolean { fn conditionally_select( mut cs: CS, cond: &Self, diff --git a/r1cs-std/src/groups/curves/short_weierstrass/mod.rs b/r1cs-std/src/groups/curves/short_weierstrass/mod.rs index 967f047..8653bf3 100644 --- a/r1cs-std/src/groups/curves/short_weierstrass/mod.rs +++ b/r1cs-std/src/groups/curves/short_weierstrass/mod.rs @@ -91,7 +91,7 @@ impl GroupGadget, ConstraintF> for AffineGadget where P: SWModelParameters, - ConstraintF: Field, + ConstraintF: PrimeField, F: FieldGadget, { type Value = SWProjective

; @@ -329,7 +329,7 @@ where impl CondSelectGadget for AffineGadget where P: SWModelParameters, - ConstraintF: Field, + ConstraintF: PrimeField, F: FieldGadget, { #[inline] @@ -424,7 +424,7 @@ impl AllocGadget, ConstraintF> for AffineGadget where P: SWModelParameters, - ConstraintF: Field, + ConstraintF: PrimeField, F: FieldGadget, { #[inline]