Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce the need for extraneous generics in downstream code. #83

Draft
wants to merge 27 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 14 additions & 30 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "ark-r1cs-std"
version = "0.3.1"
version = "0.4.0-alpha.1"
authors = [ "arkworks contributors" ]
description = "A standard library for constraint system gadgets"
homepage = "https://arkworks.rs"
Expand All @@ -13,10 +13,10 @@ license = "MIT/Apache-2.0"
edition = "2018"

[dependencies]
ark-ff = { version = "^0.3.0", default-features = false }
ark-ec = { version = "^0.3.0", default-features = false }
ark-std = { version = "^0.3.0", default-features = false }
ark-relations = { version = "^0.3.0", default-features = false }
ark-ff = { version = "0.4.0-alpha", default-features = false }
ark-ec = { version = "0.4.0-alpha", default-features = false }
ark-std = { version = "0.4.0-alpha", default-features = false }
ark-relations = { version = "0.4.0-alpha", default-features = false }

derivative = { version = "2", features = ["use_core"] }
tracing = { version = "0.1", default-features = false, features = [ "attributes" ] }
Expand All @@ -25,16 +25,16 @@ num-traits = {version = "0.2", default-features = false }
num-integer = { version = "0.1.44", default-features = false }

[dev-dependencies]
ark-test-curves = { version = "^0.3.0", default-features = false, features = ["bls12_381_scalar_field", "bls12_381_curve", "mnt4_753_scalar_field"] }
ark-poly = { version = "^0.3.0", default-features = false }
ark-test-curves = { version = "0.4.0-alpha", default-features = false, features = ["bls12_381_scalar_field", "bls12_381_curve", "mnt4_753_scalar_field"] }
ark-poly = { version = "0.4.0-alpha", default-features = false }
paste = "1.0"
ark-bls12-377 = { version = "^0.3.0", features = ["curve"], default-features = false }
ark-bls12-381 = { version = "^0.3.0", features = ["curve"], default-features = false }
ark-mnt4-298 = { version = "^0.3.0", features = ["curve"], default-features = false }
ark-mnt4-753 = { version = "^0.3.0", features = ["curve"], default-features = false }
ark-mnt6-298 = { version = "^0.3.0", default-features = false }
ark-mnt6-753 = { version = "^0.3.0", default-features = false }
ark-pallas = { version = "^0.3.0", features = ["curve"], default-features = false }
ark-bls12-377 = { version = "0.4.0-alpha", features = ["curve"], default-features = false }
ark-bls12-381 = { version = "0.4.0-alpha", features = ["curve"], default-features = false }
ark-mnt4-298 = { version = "0.4.0-alpha", features = ["curve"], default-features = false }
ark-mnt4-753 = { version = "0.4.0-alpha", features = ["curve"], default-features = false }
ark-mnt6-298 = { version = "0.4.0-alpha", default-features = false }
ark-mnt6-753 = { version = "0.4.0-alpha", default-features = false }
ark-pallas = { version = "0.4.0-alpha", features = ["curve"], default-features = false }

[features]
default = ["std"]
Expand Down Expand Up @@ -70,19 +70,3 @@ lto = "thin"
incremental = true
debug-assertions = true
debug = true

# To be removed in the new release.
[patch.crates-io]
ark-std = { git = "https://github.com/arkworks-rs/std" }
ark-ec = { git = "https://github.com/arkworks-rs/algebra" }
ark-ff = { git = "https://github.com/arkworks-rs/algebra" }
ark-poly = { git = "https://github.com/arkworks-rs/algebra" }
ark-serialize = { git = "https://github.com/arkworks-rs/algebra" }
ark-test-curves = { git = "https://github.com/arkworks-rs/algebra" }
ark-bls12-381 = { git = "https://github.com/arkworks-rs/curves" }
ark-bls12-377 = { git = "https://github.com/arkworks-rs/curves" }
ark-mnt4-298 = { git = "https://github.com/arkworks-rs/curves" }
ark-mnt4-753 = { git = "https://github.com/arkworks-rs/curves" }
ark-mnt6-298 = { git = "https://github.com/arkworks-rs/curves" }
ark-mnt6-753 = { git = "https://github.com/arkworks-rs/curves" }
ark-pallas = { git = "https://github.com/arkworks-rs/curves" }
4 changes: 2 additions & 2 deletions src/bits/boolean.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use ark_ff::{BitIteratorBE, Field, PrimeField};

use crate::{fields::fp::FpVar, prelude::*, Assignment, ToConstraintFieldGadget, Vec};

use ark_ff::{BitIteratorBE, Field, PrimeField};
use ark_relations::r1cs::{
ConstraintSystemRef, LinearCombination, Namespace, SynthesisError, Variable,
};
Expand Down
12 changes: 3 additions & 9 deletions src/bits/uint8.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use ark_ff::{Field, PrimeField, ToConstraintField};

use ark_relations::r1cs::{ConstraintSystemRef, Namespace, SynthesisError};

use crate::{
Expand Down Expand Up @@ -363,14 +362,9 @@ impl<ConstraintF: PrimeField> ToConstraintFieldGadget<ConstraintF> for Vec<UInt8
#[cfg(test)]
mod test {
use super::UInt8;
use crate::{
fields::fp::FpVar,
prelude::{
AllocationMode::{Constant, Input, Witness},
*,
},
ToConstraintFieldGadget, Vec,
};
use crate::fields::fp::FpVar;
use crate::prelude::AllocationMode::{Constant, Input, Witness};
use crate::{prelude::*, ToConstraintFieldGadget, Vec};
use ark_ff::{PrimeField, ToConstraintField};
use ark_relations::r1cs::{ConstraintSystem, SynthesisError};
use ark_std::rand::{distributions::Uniform, Rng};
Expand Down
Loading