Skip to content
This repository has been archived by the owner on Jan 26, 2022. It is now read-only.

Commit

Permalink
de-hair algebra/lib.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
jon-chuang committed Sep 10, 2020
1 parent e5cb574 commit 0df5203
Showing 1 changed file with 33 additions and 73 deletions.
106 changes: 33 additions & 73 deletions algebra/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,154 +36,114 @@ pub use algebra_core::*;
#[cfg(test)]
#[macro_use]
pub(crate) mod tests;

///////////////////////////////////////////////////////////////////////////////
#[cfg(feature = "bn254")]
#[cfg(any(feature = "bn254", feature = "ed_on_bn254"))]
#[macro_use]
pub mod bn254;

#[cfg(feature = "bn254")]
pub use bn254::Bn254;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(not(feature = "bn254"), feature = "ed_on_bn254"))]
pub(crate) mod bn254;

#[cfg(feature = "ed_on_bn254")]
pub mod ed_on_bn254;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(feature = "bls12_377")]
#[cfg(any(
feature = "ed_on_bls12_377",
feature = "cp6_782",
feature = "ed_on_cp6_782",
feature = "ed_on_bw6_761",
feature = "bw6_761",
feature = "bls12_377"
))]
#[macro_use]
pub mod bls12_377;

#[cfg(feature = "bls12_377")]
pub use bls12_377::Bls12_377;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(
not(feature = "bls12_377"),
any(
feature = "ed_on_bls12_377",
feature = "cp6_782",
feature = "ed_on_cp6_782",
feature = "ed_on_bw6_761",
feature = "bw6_761",
)
))]
#[macro_use]
pub(crate) mod bls12_377;

#[cfg(feature = "ed_on_bls12_377")]
pub mod ed_on_bls12_377;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(feature = "bls12_381")]
#[cfg(any(feature = "bls12_381", feature = "ed_on_bls12_381"))]
#[macro_use]
pub mod bls12_381;

#[cfg(feature = "bls12_381")]
pub use bls12_381::Bls12_381;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(not(feature = "bls12_381"), feature = "ed_on_bls12_381"))]
pub(crate) mod bls12_381;

#[cfg(feature = "ed_on_bls12_381")]
pub mod ed_on_bls12_381;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(
not(feature = "mnt6_298"),
any(feature = "mnt4_298", feature = "ed_on_mnt4_298")
))]
#[cfg(any(feature = "mnt6_298", feature = "mnt4_298", feature = "ed_on_mnt4_298"))]
pub(crate) mod mnt6_298;

#[cfg(feature = "mnt4_298")]
#[cfg(any(feature = "mnt4_298", feature = "ed_on_mnt4_298"))]
pub mod mnt4_298;

#[cfg(feature = "mnt4_298")]
pub use mnt4_298::MNT4_298;

#[cfg(all(not(feature = "mnt4_298"), feature = "ed_on_mnt4_298"))]
pub(crate) mod mnt4_298;

#[cfg(feature = "ed_on_mnt4_298")]
pub mod ed_on_mnt4_298;

#[cfg(feature = "mnt6_298")]
pub use mnt6_298::MNT6_298;

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(
not(feature = "mnt6_753"),
any(feature = "mnt4_753", feature = "ed_on_mnt4_753")
))]

///////////////////////////////////////////////////////////////////////////////
#[cfg(any(feature = "mnt6_753", feature = "mnt4_753", feature = "ed_on_mnt4_753"))]
pub(crate) mod mnt6_753;

#[cfg(feature = "mnt4_753")]
pub mod mnt4_753;

#[cfg(feature = "mnt4_753")]
pub use mnt4_753::MNT4_753;

#[cfg(all(not(feature = "mnt4_753"), feature = "ed_on_mnt4_753"))]
pub(crate) mod mnt4_753;

#[cfg(feature = "ed_on_mnt4_753")]
pub mod ed_on_mnt4_753;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(feature = "mnt6_298")]
pub mod mnt6_298;
#[cfg(feature = "mnt6_298")]
pub use mnt6_298::MNT6_298;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(feature = "mnt6_753")]
pub mod mnt6_753;
#[cfg(feature = "mnt6_753")]
pub use mnt6_753::MNT6_753;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(feature = "cp6_782")]
#[cfg(any(
feature = "ed_on_cp6_782",
feature = "ed_on_bw6_761",
feature = "cp6_782"
))]
pub mod cp6_782;

#[cfg(feature = "cp6_782")]
pub use cp6_782::CP6_782;

///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(feature = "bw6_761")]
#[cfg(any(feature = "bw6_761", feature = "ed_on_cp6_782"))]
pub mod bw6_761;

#[cfg(feature = "bw6_761")]
pub use bw6_761::BW6_761;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(
not(feature = "cp6_782"),
any(feature = "ed_on_cp6_782", feature = "ed_on_bw6_761")
))]
pub(crate) mod cp6_782;

#[cfg(feature = "ed_on_cp6_782")]
pub mod ed_on_cp6_782;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(not(feature = "ed_on_cp6_782"), feature = "ed_on_bw6_761"))]
#[cfg(any(feature = "ed_on_cp6_782", feature = "ed_on_bw6_761"))]
pub(crate) mod ed_on_cp6_782;

#[cfg(feature = "ed_on_bw6_761")]
pub mod ed_on_bw6_761;
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
#[cfg(all(not(feature = "bw6_761"), feature = "ed_on_cp6_782"))]
pub(crate) mod bw6_761;
///////////////////////////////////////////////////////////////////////////////

#[macro_export]
macro_rules! cfg_chunks_mut_random_gen {
($e: expr, $N: expr) => {{
Expand Down

0 comments on commit 0df5203

Please sign in to comment.