Rename all *Parameters to *Config (#136)

* Rename all `*Parameters` to `*Config`

* Tweak
This commit is contained in:
Pratyush Mishra
2022-12-16 22:35:32 -05:00
committed by GitHub
parent f8a6a4050e
commit febd7635fb
63 changed files with 382 additions and 414 deletions

View File

@@ -2,9 +2,9 @@ use crate::{constraints::FqVar, *};
use ark_r1cs_std::groups::curves::short_weierstrass::ProjectiveVar;
/// A group element in the secq256k1 curve.
pub type GVar = ProjectiveVar<Parameters, FqVar>;
pub type GVar = ProjectiveVar<Config, FqVar>;
#[test]
fn test() {
ark_curve_constraint_tests::curves::sw_test::<Parameters, GVar>().unwrap();
ark_curve_constraint_tests::curves::sw_test::<Config, GVar>().unwrap();
}

View File

@@ -9,13 +9,13 @@ use crate::{fq::Fq, fr::Fr};
#[cfg(test)]
mod tests;
pub type Affine = sw::Affine<Parameters>;
pub type Projective = sw::Projective<Parameters>;
pub type Affine = sw::Affine<Config>;
pub type Projective = sw::Projective<Config>;
#[derive(Copy, Clone, Default, PartialEq, Eq)]
pub struct Parameters;
pub struct Config;
impl CurveConfig for Parameters {
impl CurveConfig for Config {
type BaseField = Fq;
type ScalarField = Fr;
@@ -27,7 +27,7 @@ impl CurveConfig for Parameters {
const COFACTOR_INV: Fr = Fr::ONE;
}
impl SWCurveConfig for Parameters {
impl SWCurveConfig for Config {
/// COEFF_A = 0
const COEFF_A: Fq = Fq::ZERO;