mirror of
https://github.com/arnaucube/sonobe.git
synced 2026-01-28 14:56:40 +01:00
Add typos tool to CI to automate typo detection (#76)
* Add typos to CI * Apply typos suggestions * missing typos
This commit is contained in:
@@ -445,7 +445,7 @@ where
|
||||
(cf_u_i.cmE.is_zero()?).conditional_enforce_equal(&Boolean::TRUE, &is_not_basecase)?;
|
||||
(cf_u_i.u.is_one()?).conditional_enforce_equal(&Boolean::TRUE, &is_not_basecase)?;
|
||||
|
||||
// check the fold of all the parameteres of the CycleFold instances, where the elliptic
|
||||
// check the fold of all the parameters of the CycleFold instances, where the elliptic
|
||||
// curve points relations are checked natively in Curve1 circuit (this one)
|
||||
let v = NIFSFullGadget::<C2, GC2>::verify(
|
||||
cf_r_bits,
|
||||
@@ -572,7 +572,7 @@ pub mod tests {
|
||||
assert_eq!(hVar.value().unwrap(), h);
|
||||
}
|
||||
|
||||
// checks that the gadget and native implementations of the challenge computation matcbh
|
||||
// checks that the gadget and native implementations of the challenge computation match
|
||||
#[test]
|
||||
fn test_challenge_gadget() {
|
||||
let mut rng = ark_std::test_rng();
|
||||
|
||||
@@ -50,7 +50,7 @@ where
|
||||
<C2 as Group>::ScalarField: Absorb,
|
||||
C1: CurveGroup<BaseField = C2::ScalarField, ScalarField = C2::BaseField>,
|
||||
for<'b> &'b GC2: GroupOpsBounds<'b, C2, GC2>,
|
||||
// constrain FS into Nova, since this is a Decider specificly for Nova
|
||||
// constrain FS into Nova, since this is a Decider specifically for Nova
|
||||
Nova<C1, GC1, C2, GC2, FC, CP1, CP2>: From<FS>,
|
||||
{
|
||||
type ProverParam = S::ProvingKey;
|
||||
|
||||
@@ -491,11 +491,11 @@ where
|
||||
z_i: Vec<C1::ScalarField>, // last state
|
||||
num_steps: C1::ScalarField,
|
||||
running_instance: Self::CommittedInstanceWithWitness,
|
||||
incomming_instance: Self::CommittedInstanceWithWitness,
|
||||
incoming_instance: Self::CommittedInstanceWithWitness,
|
||||
cyclefold_instance: Self::CFCommittedInstanceWithWitness,
|
||||
) -> Result<(), Error> {
|
||||
let (U_i, W_i) = running_instance;
|
||||
let (u_i, w_i) = incomming_instance;
|
||||
let (u_i, w_i) = incoming_instance;
|
||||
let (cf_U_i, cf_W_i) = cyclefold_instance;
|
||||
|
||||
if u_i.x.len() != 1 || U_i.x.len() != 1 {
|
||||
|
||||
@@ -143,7 +143,7 @@ where
|
||||
// use r_T=1 since we don't need hiding property for cm(T)
|
||||
let w3 = NIFS::<C, CP>::fold_witness(r, w1, w2, T, C::ScalarField::one())?;
|
||||
|
||||
// fold committed instancs
|
||||
// fold committed instances
|
||||
let ci3 = NIFS::<C, CP>::fold_committed_instance(r, ci1, ci2, &cmT);
|
||||
|
||||
Ok((w3, ci3))
|
||||
@@ -161,7 +161,7 @@ where
|
||||
NIFS::<C, CP>::fold_committed_instance(r, ci1, ci2, cmT)
|
||||
}
|
||||
|
||||
/// Verify commited folded instance (ci) relations. Notice that this method does not open the
|
||||
/// Verify committed folded instance (ci) relations. Notice that this method does not open the
|
||||
/// commitments, but just checks that the given committed instances (ci1, ci2) when folded
|
||||
/// result in the folded committed instance (ci3) values.
|
||||
pub fn verify_folded_instance(
|
||||
@@ -426,16 +426,16 @@ pub mod tests {
|
||||
|
||||
let num_iters = 10;
|
||||
for i in 0..num_iters {
|
||||
// prepare the incomming instance
|
||||
let incomming_instance_z = get_test_z(i + 4);
|
||||
let (w, x) = r1cs.split_z(&incomming_instance_z);
|
||||
let incomming_instance_w = Witness::<Projective>::new(w.clone(), r1cs.A.n_rows);
|
||||
let incomming_committed_instance = incomming_instance_w
|
||||
// prepare the incoming instance
|
||||
let incoming_instance_z = get_test_z(i + 4);
|
||||
let (w, x) = r1cs.split_z(&incoming_instance_z);
|
||||
let incoming_instance_w = Witness::<Projective>::new(w.clone(), r1cs.A.n_rows);
|
||||
let incoming_committed_instance = incoming_instance_w
|
||||
.commit::<Pedersen<Projective>>(&pedersen_params, x)
|
||||
.unwrap();
|
||||
r1cs.check_relaxed_instance_relation(
|
||||
&incomming_instance_w,
|
||||
&incomming_committed_instance,
|
||||
&incoming_instance_w,
|
||||
&incoming_committed_instance,
|
||||
)
|
||||
.unwrap();
|
||||
|
||||
@@ -447,16 +447,16 @@ pub mod tests {
|
||||
&r1cs,
|
||||
&running_instance_w,
|
||||
&running_committed_instance,
|
||||
&incomming_instance_w,
|
||||
&incomming_committed_instance,
|
||||
&incoming_instance_w,
|
||||
&incoming_committed_instance,
|
||||
)
|
||||
.unwrap();
|
||||
let (folded_w, _) = NIFS::<Projective, Pedersen<Projective>>::fold_instances(
|
||||
r,
|
||||
&running_instance_w,
|
||||
&running_committed_instance,
|
||||
&incomming_instance_w,
|
||||
&incomming_committed_instance,
|
||||
&incoming_instance_w,
|
||||
&incoming_committed_instance,
|
||||
&T,
|
||||
cmT,
|
||||
)
|
||||
@@ -466,7 +466,7 @@ pub mod tests {
|
||||
let folded_committed_instance = NIFS::<Projective, Pedersen<Projective>>::verify(
|
||||
r,
|
||||
&running_committed_instance,
|
||||
&incomming_committed_instance,
|
||||
&incoming_committed_instance,
|
||||
&cmT,
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user