mirror of
https://github.com/Qortal/pirate-librustzcash.git
synced 2025-02-11 17:55:46 +00:00
bls12_381: Fix ambiguous operation clippy warnings
This commit is contained in:
parent
e15fea2757
commit
687fff5ecf
@ -1046,7 +1046,7 @@ fn test_projective_addition() {
|
||||
|
||||
let mut d = G1Projective::generator();
|
||||
for _ in 0..5 {
|
||||
d = d + G1Projective::generator();
|
||||
d += G1Projective::generator();
|
||||
}
|
||||
assert!(!bool::from(c.is_identity()));
|
||||
assert!(bool::from(c.is_on_curve()));
|
||||
@ -1167,7 +1167,7 @@ fn test_mixed_addition() {
|
||||
|
||||
let mut d = G1Projective::generator();
|
||||
for _ in 0..5 {
|
||||
d = d + G1Affine::generator();
|
||||
d += G1Affine::generator();
|
||||
}
|
||||
assert!(!bool::from(c.is_identity()));
|
||||
assert!(bool::from(c.is_on_curve()));
|
||||
|
@ -1208,7 +1208,7 @@ fn test_projective_addition() {
|
||||
|
||||
let mut d = G2Projective::generator();
|
||||
for _ in 0..5 {
|
||||
d = d + G2Projective::generator();
|
||||
d += G2Projective::generator();
|
||||
}
|
||||
assert!(!bool::from(c.is_identity()));
|
||||
assert!(bool::from(c.is_on_curve()));
|
||||
@ -1372,7 +1372,7 @@ fn test_mixed_addition() {
|
||||
|
||||
let mut d = G2Projective::generator();
|
||||
for _ in 0..5 {
|
||||
d = d + G2Affine::generator();
|
||||
d += G2Affine::generator();
|
||||
}
|
||||
assert!(!bool::from(c.is_identity()));
|
||||
assert!(bool::from(c.is_on_curve()));
|
||||
|
@ -57,28 +57,28 @@ impl MillerLoopResult {
|
||||
|
||||
// For A
|
||||
z0 = t0 - z0;
|
||||
z0 += z0 + t0;
|
||||
z0 = z0 + z0 + t0;
|
||||
|
||||
z1 = t1 + z1;
|
||||
z1 += z1 + t1;
|
||||
z1 = z1 + z1 + t1;
|
||||
|
||||
let (mut t0, t1) = fp4_square(z2, z3);
|
||||
let (t2, t3) = fp4_square(z4, z5);
|
||||
|
||||
// For C
|
||||
z4 = t0 - z4;
|
||||
z4 += z4 + t0;
|
||||
z4 = z4 + z4 + t0;
|
||||
|
||||
z5 = t1 + z5;
|
||||
z5 += z5 + t1;
|
||||
z5 = z5 + z5 + t1;
|
||||
|
||||
// For B
|
||||
t0 = t3.mul_by_nonresidue();
|
||||
z2 = t0 + z2;
|
||||
z2 += z2 + t0;
|
||||
z2 = z2 + z2 + t0;
|
||||
|
||||
z3 = t2 - z3;
|
||||
z3 += z3 + t2;
|
||||
z3 = z3 + z3 + t2;
|
||||
|
||||
Fp12 {
|
||||
c0: Fp6 {
|
||||
|
Loading…
x
Reference in New Issue
Block a user