Making bn no_std. Exposing miller_loop_batch and final_exponentiation. (#16)

This commit is contained in:
Maciej Zieliński
2020-01-21 14:44:14 +01:00
committed by Nikolay Volf
parent b1611b623e
commit 635c4cdd56
9 changed files with 55 additions and 35 deletions
+4 -4
View File
@@ -1,12 +1,12 @@
use alloc::vec::Vec;
use core::ops::{Add, Mul, Neg, Sub};
use rand::Rng;
use std::ops::{Add, Mul, Neg, Sub};
use super::FieldElement;
use fields::FieldElement;
use arith::{U256, U512};
#[cfg(feature = "rustc-serialize")]
use rustc_serialize::{Decodable, Decoder, Encodable, Encoder};
use arith::{U256, U512};
macro_rules! field_impl {
($name:ident, $modulus:expr, $rsquared:expr, $rcubed:expr, $one:expr, $inv:expr) => {
#[derive(Copy, Clone, PartialEq, Eq, Debug)]