[INFO] fetching crate modular_math 0.1.6... [INFO] testing modular_math-0.1.6 against master#cdb45c87e2cd43495379f7e867e3cc15dcee9f93 for pr-145838-1 [INFO] extracting crate modular_math 0.1.6 into /workspace/builds/worker-3-tc1/source [INFO] started tweaking crates.io crate modular_math 0.1.6 [INFO] finished tweaking crates.io crate modular_math 0.1.6 [INFO] tweaked toml for crates.io crate modular_math 0.1.6 written to /workspace/builds/worker-3-tc1/source/Cargo.toml [INFO] validating manifest of crates.io crate modular_math 0.1.6 on toolchain cdb45c87e2cd43495379f7e867e3cc15dcee9f93 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+cdb45c87e2cd43495379f7e867e3cc15dcee9f93" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+cdb45c87e2cd43495379f7e867e3cc15dcee9f93" "generate-lockfile" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Locking 47 packages to latest compatible versions [INFO] [stderr] Adding primitive-types v0.12.2 (available: v0.13.1) [INFO] [stderr] Adding rand v0.8.5 (available: v0.9.2) [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+cdb45c87e2cd43495379f7e867e3cc15dcee9f93" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:7ad1b28ee6f5f7f699f6cf7015098d6ccdd96d6f2d78dd06228f5b4c9faf309c" "/opt/rustwide/cargo-home/bin/cargo" "+cdb45c87e2cd43495379f7e867e3cc15dcee9f93" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 83bf8ebe5978ae5b5b9bb6ec4494d924b2119b8ba0248a5c084fcea93b36d81e [INFO] running `Command { std: "docker" "start" "-a" "83bf8ebe5978ae5b5b9bb6ec4494d924b2119b8ba0248a5c084fcea93b36d81e", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "83bf8ebe5978ae5b5b9bb6ec4494d924b2119b8ba0248a5c084fcea93b36d81e", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "83bf8ebe5978ae5b5b9bb6ec4494d924b2119b8ba0248a5c084fcea93b36d81e", kill_on_drop: false }` [INFO] [stdout] 83bf8ebe5978ae5b5b9bb6ec4494d924b2119b8ba0248a5c084fcea93b36d81e [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:7ad1b28ee6f5f7f699f6cf7015098d6ccdd96d6f2d78dd06228f5b4c9faf309c" "/opt/rustwide/cargo-home/bin/cargo" "+cdb45c87e2cd43495379f7e867e3cc15dcee9f93" "build" "--frozen" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 6bbd255a31697c8e5ac505b8695a4c8ecc19f16369fc99fa6cb97b9feed83c92 [INFO] running `Command { std: "docker" "start" "-a" "6bbd255a31697c8e5ac505b8695a4c8ecc19f16369fc99fa6cb97b9feed83c92", kill_on_drop: false }` [INFO] [stderr] Compiling libc v0.2.175 [INFO] [stderr] Compiling zerocopy v0.8.26 [INFO] [stderr] Compiling cfg-if v1.0.3 [INFO] [stderr] Compiling crunchy v0.2.4 [INFO] [stderr] Compiling byteorder v1.5.0 [INFO] [stderr] Compiling static_assertions v1.1.0 [INFO] [stderr] Compiling hex v0.4.3 [INFO] [stderr] Compiling rustc-hex v2.1.0 [INFO] [stderr] Compiling uint v0.9.5 [INFO] [stderr] Compiling getrandom v0.2.16 [INFO] [stderr] Compiling rand_core v0.6.4 [INFO] [stderr] Compiling ppv-lite86 v0.2.21 [INFO] [stderr] Compiling rand_chacha v0.3.1 [INFO] [stderr] Compiling rand v0.8.5 [INFO] [stderr] Compiling fixed-hash v0.8.0 [INFO] [stderr] Compiling primitive-types v0.12.2 [INFO] [stderr] Compiling modular_math v0.1.6 (/opt/rustwide/workdir) [INFO] [stdout] warning: unnecessary parentheses around `while` condition [INFO] [stdout] --> src/mod_math/mod_math.rs:285:19 [INFO] [stdout] | [INFO] [stdout] 285 | while (m < r) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 285 - while (m < r) { [INFO] [stdout] 285 + while m < r { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ModMath` [INFO] [stdout] --> src/galois_field/galois_field.rs:1:23 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::error::Error` [INFO] [stdout] --> src/galois_field/galois_field.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | use std::error::Error; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `RngCore` and `rngs::OsRng` [INFO] [stdout] --> src/curves/elliptical_curve.rs:2:12 [INFO] [stdout] | [INFO] [stdout] 2 | use rand::{rngs::OsRng, RngCore}; [INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `IntoU256` [INFO] [stdout] --> src/curves/elliptical_curve.rs:4:32 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `coefficients` [INFO] [stdout] --> src/galois_field/galois_field.rs:31:37 [INFO] [stdout] | [INFO] [stdout] 31 | pub fn poly(&self, coefficients: Vec) -> GaloisFieldPolynomial { [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_coefficients` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `polynomial` is never read [INFO] [stdout] --> src/galois_field/galois_field.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 12 | pub struct GaloisFieldPolynomial { [INFO] [stdout] | --------------------- field in this struct [INFO] [stdout] 13 | polynomial: Vec, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `GaloisFieldError` is never used [INFO] [stdout] --> src/galois_field/galois_field.rs:77:10 [INFO] [stdout] | [INFO] [stdout] 77 | pub enum GaloisFieldError { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `b` is never read [INFO] [stdout] --> src/curves/elliptical_curve.rs:67:3 [INFO] [stdout] | [INFO] [stdout] 64 | pub struct Curve { [INFO] [stdout] | ----- field in this struct [INFO] [stdout] ... [INFO] [stdout] 67 | b: U256, [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Secp256k1` is never used [INFO] [stdout] --> src/curves/curves.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn Secp256k1() -> Curve { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `G` should have a snake case name [INFO] [stdout] --> src/curves/elliptical_curve.rs:70:7 [INFO] [stdout] | [INFO] [stdout] 70 | pub G: ECPoint // Generator Point [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/elliptical_curve.rs:75:72 [INFO] [stdout] | [INFO] [stdout] 75 | pub fn new(a: U256, b: U256, field_modulus: U256, curve_order: U256, G: ECPoint) -> Self { [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `BN128` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:6:8 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn BN128() -> Curve { [INFO] [stdout] | ^^^^^ help: convert the identifier to snake case: `bn128` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | let G = ECPoint::new(U256::from(1), U256::from(2)); [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Secp256k1` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn Secp256k1() -> Curve { [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case (notice the capitalization): `secp256k1` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:25:7 [INFO] [stdout] | [INFO] [stdout] 25 | let G = ECPoint::new(U256::from_dec_str("55066263022277343669578718895168534326250603453777594175500187360389116729240").unwrap(), [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 7.82s [INFO] running `Command { std: "docker" "inspect" "6bbd255a31697c8e5ac505b8695a4c8ecc19f16369fc99fa6cb97b9feed83c92", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "6bbd255a31697c8e5ac505b8695a4c8ecc19f16369fc99fa6cb97b9feed83c92", kill_on_drop: false }` [INFO] [stdout] 6bbd255a31697c8e5ac505b8695a4c8ecc19f16369fc99fa6cb97b9feed83c92 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:7ad1b28ee6f5f7f699f6cf7015098d6ccdd96d6f2d78dd06228f5b4c9faf309c" "/opt/rustwide/cargo-home/bin/cargo" "+cdb45c87e2cd43495379f7e867e3cc15dcee9f93" "test" "--frozen" "--no-run" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 5a47673b8a682b3cb93742e25fe560efd57b39194821d4f5bc529a70dc3016ba [INFO] running `Command { std: "docker" "start" "-a" "5a47673b8a682b3cb93742e25fe560efd57b39194821d4f5bc529a70dc3016ba", kill_on_drop: false }` [INFO] [stdout] warning: unnecessary parentheses around `while` condition [INFO] [stdout] --> src/mod_math/mod_math.rs:285:19 [INFO] [stdout] | [INFO] [stdout] 285 | while (m < r) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 285 - while (m < r) { [INFO] [stdout] 285 + while m < r { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ModMath` [INFO] [stdout] --> src/galois_field/galois_field.rs:1:23 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::error::Error` [INFO] [stdout] --> src/galois_field/galois_field.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | use std::error::Error; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `RngCore` and `rngs::OsRng` [INFO] [stdout] --> src/curves/elliptical_curve.rs:2:12 [INFO] [stdout] | [INFO] [stdout] 2 | use rand::{rngs::OsRng, RngCore}; [INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `IntoU256` [INFO] [stdout] --> src/curves/elliptical_curve.rs:4:32 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `coefficients` [INFO] [stdout] --> src/galois_field/galois_field.rs:31:37 [INFO] [stdout] | [INFO] [stdout] 31 | pub fn poly(&self, coefficients: Vec) -> GaloisFieldPolynomial { [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_coefficients` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `polynomial` is never read [INFO] [stdout] --> src/galois_field/galois_field.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 12 | pub struct GaloisFieldPolynomial { [INFO] [stdout] | --------------------- field in this struct [INFO] [stdout] 13 | polynomial: Vec, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `GaloisFieldError` is never used [INFO] [stdout] --> src/galois_field/galois_field.rs:77:10 [INFO] [stdout] | [INFO] [stdout] 77 | pub enum GaloisFieldError { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `b` is never read [INFO] [stdout] --> src/curves/elliptical_curve.rs:67:3 [INFO] [stdout] | [INFO] [stdout] 64 | pub struct Curve { [INFO] [stdout] | ----- field in this struct [INFO] [stdout] ... [INFO] [stdout] 67 | b: U256, [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Secp256k1` is never used [INFO] [stdout] --> src/curves/curves.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn Secp256k1() -> Curve { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `G` should have a snake case name [INFO] [stdout] --> src/curves/elliptical_curve.rs:70:7 [INFO] [stdout] | [INFO] [stdout] 70 | pub G: ECPoint // Generator Point [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/elliptical_curve.rs:75:72 [INFO] [stdout] | [INFO] [stdout] 75 | pub fn new(a: U256, b: U256, field_modulus: U256, curve_order: U256, G: ECPoint) -> Self { [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `BN128` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:6:8 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn BN128() -> Curve { [INFO] [stdout] | ^^^^^ help: convert the identifier to snake case: `bn128` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | let G = ECPoint::new(U256::from(1), U256::from(2)); [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Secp256k1` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn Secp256k1() -> Curve { [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case (notice the capitalization): `secp256k1` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:25:7 [INFO] [stdout] | [INFO] [stdout] 25 | let G = ECPoint::new(U256::from_dec_str("55066263022277343669578718895168534326250603453777594175500187360389116729240").unwrap(), [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Compiling modular_math v0.1.6 (/opt/rustwide/workdir) [INFO] [stdout] warning: unnecessary parentheses around `while` condition [INFO] [stdout] --> src/mod_math/mod_math.rs:285:19 [INFO] [stdout] | [INFO] [stdout] 285 | while (m < r) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 285 - while (m < r) { [INFO] [stdout] 285 + while m < r { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ModMath` [INFO] [stdout] --> src/galois_field/galois_field.rs:1:23 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::error::Error` [INFO] [stdout] --> src/galois_field/galois_field.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | use std::error::Error; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `primitive_types::U256` [INFO] [stdout] --> src/galois_field/galois_field_test.rs:4:7 [INFO] [stdout] | [INFO] [stdout] 4 | use primitive_types::U256; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `primitive_types::U256` [INFO] [stdout] --> src/number_mod/number_mod_test.rs:4:9 [INFO] [stdout] | [INFO] [stdout] 4 | use primitive_types::U256; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `RngCore` and `rngs::OsRng` [INFO] [stdout] --> src/curves/elliptical_curve.rs:2:12 [INFO] [stdout] | [INFO] [stdout] 2 | use rand::{rngs::OsRng, RngCore}; [INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `IntoU256` [INFO] [stdout] --> src/curves/elliptical_curve.rs:4:32 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `num` [INFO] [stdout] --> src/mod_math/mod_math_test.rs:77:13 [INFO] [stdout] | [INFO] [stdout] 77 | let num = U256::from_dec_str("32670510020758816978083085130507043184471273380659243275938904335757337482424").unwrap(); [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_num` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `coefficients` [INFO] [stdout] --> src/galois_field/galois_field.rs:31:37 [INFO] [stdout] | [INFO] [stdout] 31 | pub fn poly(&self, coefficients: Vec) -> GaloisFieldPolynomial { [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_coefficients` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `G` [INFO] [stdout] --> src/curves/bn128_test.rs:25:9 [INFO] [stdout] | [INFO] [stdout] 25 | let G = bn128.G; [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_G` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `polynomial` is never read [INFO] [stdout] --> src/galois_field/galois_field.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 12 | pub struct GaloisFieldPolynomial { [INFO] [stdout] | --------------------- field in this struct [INFO] [stdout] 13 | polynomial: Vec, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `GaloisFieldError` is never used [INFO] [stdout] --> src/galois_field/galois_field.rs:77:10 [INFO] [stdout] | [INFO] [stdout] 77 | pub enum GaloisFieldError { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `b` is never read [INFO] [stdout] --> src/curves/elliptical_curve.rs:67:3 [INFO] [stdout] | [INFO] [stdout] 64 | pub struct Curve { [INFO] [stdout] | ----- field in this struct [INFO] [stdout] ... [INFO] [stdout] 67 | b: U256, [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Secp256k1` is never used [INFO] [stdout] --> src/curves/curves.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn Secp256k1() -> Curve { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `GF7` should have a snake case name [INFO] [stdout] --> src/galois_field/galois_field_test.rs:8:9 [INFO] [stdout] | [INFO] [stdout] 8 | let GF7 = GaloisField::new(7).unwrap(); [INFO] [stdout] | ^^^ help: convert the identifier to snake case: `gf7` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `G` should have a snake case name [INFO] [stdout] --> src/curves/elliptical_curve.rs:70:7 [INFO] [stdout] | [INFO] [stdout] 70 | pub G: ECPoint // Generator Point [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/elliptical_curve.rs:75:72 [INFO] [stdout] | [INFO] [stdout] 75 | pub fn new(a: U256, b: U256, field_modulus: U256, curve_order: U256, G: ECPoint) -> Self { [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `BN128` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:6:8 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn BN128() -> Curve { [INFO] [stdout] | ^^^^^ help: convert the identifier to snake case: `bn128` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | let G = ECPoint::new(U256::from(1), U256::from(2)); [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Secp256k1` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn Secp256k1() -> Curve { [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case (notice the capitalization): `secp256k1` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/curves.rs:25:7 [INFO] [stdout] | [INFO] [stdout] 25 | let G = ECPoint::new(U256::from_dec_str("55066263022277343669578718895168534326250603453777594175500187360389116729240").unwrap(), [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/bn128_test.rs:9:9 [INFO] [stdout] | [INFO] [stdout] 9 | let G = bn128.G; [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `double_G` should have a snake case name [INFO] [stdout] --> src/curves/bn128_test.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 11 | let double_G = bn128.add_points(&G, &G); [INFO] [stdout] | ^^^^^^^^ help: convert the identifier to snake case: `double_g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `triple_G` should have a snake case name [INFO] [stdout] --> src/curves/bn128_test.rs:12:9 [INFO] [stdout] | [INFO] [stdout] 12 | let triple_G = bn128.add_points(&double_G, &G); [INFO] [stdout] | ^^^^^^^^ help: convert the identifier to snake case: `triple_g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `G` should have a snake case name [INFO] [stdout] --> src/curves/bn128_test.rs:25:9 [INFO] [stdout] | [INFO] [stdout] 25 | let G = bn128.G; [INFO] [stdout] | ^ help: convert the identifier to snake case: `g` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `double_G` should have a snake case name [INFO] [stdout] --> src/curves/bn128_test.rs:27:9 [INFO] [stdout] | [INFO] [stdout] 27 | let double_G = bn128.scalar_multiply_generator(U256::from(2)); [INFO] [stdout] | ^^^^^^^^ help: convert the identifier to snake case: `double_g` [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `test` profile [unoptimized + debuginfo] target(s) in 0.67s [INFO] running `Command { std: "docker" "inspect" "5a47673b8a682b3cb93742e25fe560efd57b39194821d4f5bc529a70dc3016ba", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "5a47673b8a682b3cb93742e25fe560efd57b39194821d4f5bc529a70dc3016ba", kill_on_drop: false }` [INFO] [stdout] 5a47673b8a682b3cb93742e25fe560efd57b39194821d4f5bc529a70dc3016ba [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:7ad1b28ee6f5f7f699f6cf7015098d6ccdd96d6f2d78dd06228f5b4c9faf309c" "/opt/rustwide/cargo-home/bin/cargo" "+cdb45c87e2cd43495379f7e867e3cc15dcee9f93" "test" "--frozen", kill_on_drop: false }` [INFO] [stdout] 67714525b123dac4fb5b24636200955c459c5f86c1ee15ced5fc933769cf4c60 [INFO] running `Command { std: "docker" "start" "-a" "67714525b123dac4fb5b24636200955c459c5f86c1ee15ced5fc933769cf4c60", kill_on_drop: false }` [INFO] [stderr] warning: unnecessary parentheses around `while` condition [INFO] [stderr] --> src/mod_math/mod_math.rs:285:19 [INFO] [stderr] | [INFO] [stderr] 285 | while (m < r) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 285 - while (m < r) { [INFO] [stderr] 285 + while m < r { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: unused import: `ModMath` [INFO] [stderr] --> src/galois_field/galois_field.rs:1:23 [INFO] [stderr] | [INFO] [stderr] 1 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stderr] | ^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stderr] [INFO] [stderr] warning: unused import: `std::error::Error` [INFO] [stderr] --> src/galois_field/galois_field.rs:5:5 [INFO] [stderr] | [INFO] [stderr] 5 | use std::error::Error; [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: unused imports: `RngCore` and `rngs::OsRng` [INFO] [stderr] --> src/curves/elliptical_curve.rs:2:12 [INFO] [stderr] | [INFO] [stderr] 2 | use rand::{rngs::OsRng, RngCore}; [INFO] [stderr] | ^^^^^^^^^^^ ^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: unused import: `IntoU256` [INFO] [stderr] --> src/curves/elliptical_curve.rs:4:32 [INFO] [stderr] | [INFO] [stderr] 4 | use crate::mod_math::{ModMath, IntoU256}; [INFO] [stderr] | ^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: unused variable: `coefficients` [INFO] [stderr] --> src/galois_field/galois_field.rs:31:37 [INFO] [stderr] | [INFO] [stderr] 31 | pub fn poly(&self, coefficients: Vec) -> GaloisFieldPolynomial { [INFO] [stderr] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_coefficients` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stderr] [INFO] [stderr] warning: field `polynomial` is never read [INFO] [stderr] --> src/galois_field/galois_field.rs:13:5 [INFO] [stderr] | [INFO] [stderr] 12 | pub struct GaloisFieldPolynomial { [INFO] [stderr] | --------------------- field in this struct [INFO] [stderr] 13 | polynomial: Vec, [INFO] [stderr] | ^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stderr] [INFO] [stderr] warning: enum `GaloisFieldError` is never used [INFO] [stderr] --> src/galois_field/galois_field.rs:77:10 [INFO] [stderr] | [INFO] [stderr] 77 | pub enum GaloisFieldError { [INFO] [stderr] | ^^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: field `b` is never read [INFO] [stderr] --> src/curves/elliptical_curve.rs:67:3 [INFO] [stderr] | [INFO] [stderr] 64 | pub struct Curve { [INFO] [stderr] | ----- field in this struct [INFO] [stderr] ... [INFO] [stderr] 67 | b: U256, [INFO] [stderr] | ^ [INFO] [stderr] [INFO] [stderr] warning: function `Secp256k1` is never used [INFO] [stderr] --> src/curves/curves.rs:19:8 [INFO] [stderr] | [INFO] [stderr] 19 | pub fn Secp256k1() -> Curve { [INFO] [stderr] | ^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: structure field `G` should have a snake case name [INFO] [stderr] --> src/curves/elliptical_curve.rs:70:7 [INFO] [stderr] | [INFO] [stderr] 70 | pub G: ECPoint // Generator Point [INFO] [stderr] | ^ help: convert the identifier to snake case: `g` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stderr] [INFO] [stderr] warning: variable `G` should have a snake case name [INFO] [stderr] --> src/curves/elliptical_curve.rs:75:72 [INFO] [stderr] | [INFO] [stderr] 75 | pub fn new(a: U256, b: U256, field_modulus: U256, curve_order: U256, G: ECPoint) -> Self { [INFO] [stderr] | ^ help: convert the identifier to snake case: `g` [INFO] [stderr] [INFO] [stderr] warning: function `BN128` should have a snake case name [INFO] [stderr] --> src/curves/curves.rs:6:8 [INFO] [stderr] | [INFO] [stderr] 6 | pub fn BN128() -> Curve { [INFO] [stderr] | ^^^^^ help: convert the identifier to snake case: `bn128` [INFO] [stderr] [INFO] [stderr] warning: variable `G` should have a snake case name [INFO] [stderr] --> src/curves/curves.rs:11:7 [INFO] [stderr] | [INFO] [stderr] 11 | let G = ECPoint::new(U256::from(1), U256::from(2)); [INFO] [stderr] | ^ help: convert the identifier to snake case: `g` [INFO] [stderr] [INFO] [stderr] warning: function `Secp256k1` should have a snake case name [INFO] [stderr] --> src/curves/curves.rs:19:8 [INFO] [stderr] | [INFO] [stderr] 19 | pub fn Secp256k1() -> Curve { [INFO] [stderr] | ^^^^^^^^^ help: convert the identifier to snake case (notice the capitalization): `secp256k1` [INFO] [stderr] [INFO] [stderr] warning: variable `G` should have a snake case name [INFO] [stderr] --> src/curves/curves.rs:25:7 [INFO] [stderr] | [INFO] [stderr] 25 | let G = ECPoint::new(U256::from_dec_str("55066263022277343669578718895168534326250603453777594175500187360389116729240").unwrap(), [INFO] [stderr] | ^ help: convert the identifier to snake case: `g` [INFO] [stderr] [INFO] [stderr] warning: `modular_math` (lib) generated 16 warnings (run `cargo fix --lib -p modular_math` to apply 5 suggestions) [INFO] [stderr] warning: unused import: `primitive_types::U256` [INFO] [stderr] --> src/galois_field/galois_field_test.rs:4:7 [INFO] [stderr] | [INFO] [stderr] 4 | use primitive_types::U256; [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: unused import: `primitive_types::U256` [INFO] [stderr] --> src/number_mod/number_mod_test.rs:4:9 [INFO] [stderr] | [INFO] [stderr] 4 | use primitive_types::U256; [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: unused variable: `num` [INFO] [stderr] --> src/mod_math/mod_math_test.rs:77:13 [INFO] [stderr] | [INFO] [stderr] 77 | let num = U256::from_dec_str("32670510020758816978083085130507043184471273380659243275938904335757337482424").unwrap(); [INFO] [stderr] | ^^^ help: if this is intentional, prefix it with an underscore: `_num` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stderr] [INFO] [stderr] warning: unused variable: `coefficients` [INFO] [stderr] --> src/galois_field/galois_field.rs:31:37 [INFO] [stderr] | [INFO] [stderr] 31 | pub fn poly(&self, coefficients: Vec) -> GaloisFieldPolynomial { [INFO] [stderr] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_coefficients` [INFO] [stderr] [INFO] [stderr] warning: unused variable: `G` [INFO] [stderr] --> src/curves/bn128_test.rs:25:9 [INFO] [stderr] | [INFO] [stderr] 25 | let G = bn128.G; [INFO] [stderr] | ^ help: if this is intentional, prefix it with an underscore: `_G` [INFO] [stderr] [INFO] [stderr] warning: variable `GF7` should have a snake case name [INFO] [stderr] --> src/galois_field/galois_field_test.rs:8:9 [INFO] [stderr] | [INFO] [stderr] 8 | let GF7 = GaloisField::new(7).unwrap(); [INFO] [stderr] | ^^^ help: convert the identifier to snake case: `gf7` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stderr] [INFO] [stderr] warning: structure field `G` should have a snake case name [INFO] [stderr] --> src/curves/elliptical_curve.rs:70:7 [INFO] [stderr] | [INFO] [stderr] 70 | pub G: ECPoint // Generator Point [INFO] [stderr] | ^ help: convert the identifier to snake case: `g` [INFO] [stderr] [INFO] [stderr] warning: variable `G` should have a snake case name [INFO] [stderr] --> src/curves/bn128_test.rs:9:9 [INFO] [stderr] | [INFO] [stderr] 9 | let G = bn128.G; [INFO] [stderr] | ^ help: convert the identifier to snake case: `g` [INFO] [stderr] [INFO] [stderr] warning: variable `double_G` should have a snake case name [INFO] [stderr] --> src/curves/bn128_test.rs:11:9 [INFO] [stderr] | [INFO] [stderr] 11 | let double_G = bn128.add_points(&G, &G); [INFO] [stderr] | ^^^^^^^^ help: convert the identifier to snake case: `double_g` [INFO] [stderr] [INFO] [stderr] warning: variable `triple_G` should have a snake case name [INFO] [stderr] --> src/curves/bn128_test.rs:12:9 [INFO] [stderr] | [INFO] [stderr] 12 | let triple_G = bn128.add_points(&double_G, &G); [INFO] [stderr] | ^^^^^^^^ help: convert the identifier to snake case: `triple_g` [INFO] [stderr] [INFO] [stderr] warning: variable `G` should have a snake case name [INFO] [stderr] --> src/curves/bn128_test.rs:25:9 [INFO] [stderr] | [INFO] [stderr] 25 | let G = bn128.G; [INFO] [stderr] | ^ help: convert the identifier to snake case: `g` [INFO] [stderr] [INFO] [stderr] warning: variable `double_G` should have a snake case name [INFO] [stderr] --> src/curves/bn128_test.rs:27:9 [INFO] [stderr] | [INFO] [stderr] 27 | let double_G = bn128.scalar_multiply_generator(U256::from(2)); [INFO] [stderr] | ^^^^^^^^ help: convert the identifier to snake case: `double_g` [INFO] [stderr] [INFO] [stderr] warning: `modular_math` (lib test) generated 26 warnings (14 duplicates) (run `cargo fix --lib -p modular_math --tests` to apply 2 suggestions) [INFO] [stderr] Finished `test` profile [unoptimized + debuginfo] target(s) in 0.19s [INFO] [stderr] Running unittests src/lib.rs (/opt/rustwide/target/debug/deps/modular_math-ead2b9283db7574b) [INFO] [stdout] [INFO] [stdout] running 23 tests [INFO] [stdout] test mod_math::mod_math_test::tests::test_big_number_modulus ... ok [INFO] [stdout] test curves::bn128_test::tests::test_point_addition ... ok [INFO] [stdout] test galois_field::galois_field_test::tests::test_new_galois_field ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_add ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_div ... ok [INFO] [stdout] test curves::bn128_test::tests::test_point_doubling ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_exp ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_into_u256 ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_sqrt ... ok [INFO] [stdout] test curves::bn128_test::tests::test_scalar_multiply_generator ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_mod_inv ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_multiply ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_secp256k1 ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_square ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_sub ... ok [INFO] [stdout] test number_mod::number_mod_test::tests::test_division ... ok [INFO] [stdout] test number_mod::number_mod_test::tests::test_equality ... ok [INFO] [stdout] test number_mod::number_mod_test::tests::test_inequality ... ok [INFO] [stdout] test number_mod::number_mod_test::tests::test_subtraction ... ok [INFO] [stdout] test number_mod::number_mod_test::tests::test_multiplication ... ok [INFO] [stdout] test number_mod::number_mod_test::tests::test_addition ... ok [INFO] [stdout] test number_mod::number_mod_test::tests::test_negation ... ok [INFO] [stdout] test mod_math::mod_math_test::tests::test_into_u256_negative - should panic ... ok [INFO] [stdout] [INFO] [stdout] test result: ok. 23 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.04s [INFO] [stdout] [INFO] [stderr] Doc-tests modular_math [INFO] [stderr] warning: unnecessary parentheses around `while` condition [INFO] [stderr] --> src/mod_math/mod_math.rs:285:19 [INFO] [stderr] | [INFO] [stderr] 285 | while (m < r) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 285 - while (m < r) { [INFO] [stderr] 285 + while m < r { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: 1 warning emitted [INFO] [stderr] [INFO] [stdout] [INFO] [stdout] running 10 tests [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint::eq (line 41) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_addition (line 110) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve (line 59) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_multiplication_scalar (line 185) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_doubling (line 139) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint::new (line 30) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint (line 13) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::add_points (line 92) ... FAILED [INFO] [stdout] test src/number_mod/number_mod.rs - number_mod::number_mod::NumberUnderMod (line 31) ... FAILED [INFO] [stdout] test src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::scalar_multiply_generator (line 171) ... FAILED [INFO] [stdout] [INFO] [stdout] failures: [INFO] [stdout] [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint::eq (line 41) stdout ---- [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:42:14 [INFO] [stdout] | [INFO] [stdout] 3 | let point1 = ECPoint::new(5.into(), 7.into()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:43:14 [INFO] [stdout] | [INFO] [stdout] 4 | let point2 = ECPoint::new(5.into(), 7.into()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error: aborting due to 2 previous errors [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_addition (line 110) stdout ---- [INFO] [stdout] error: unexpected token: `...` [INFO] [stdout] --> src/curves/elliptical_curve.rs:111:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] help: use `..` for an exclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] help: or `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..=; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0586]: inclusive range with no end [INFO] [stdout] --> src/curves/elliptical_curve.rs:111:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`) [INFO] [stdout] help: use `..` instead [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:112:10 [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:113:10 [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:112:25 [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5_i32.into_u256(), 7.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:112:40 [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:113:25 [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3_i32.into_u256(), 2.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:113:40 [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error: aborting due to 8 previous errors [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0433, E0586, E0689. [INFO] [stdout] For more information about an error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve (line 59) stdout ---- [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:60:9 [INFO] [stdout] | [INFO] [stdout] 3 | let G = ECPoint::new(1.into_u256(), 1.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `Curve` [INFO] [stdout] --> src/curves/elliptical_curve.rs:61:13 [INFO] [stdout] | [INFO] [stdout] 4 | let curve = Curve::new(0.into(), 7.into_u256(), 11.into_u256(), 5.into_u256(), G); [INFO] [stdout] | ^^^^^ use of undeclared type `Curve` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::Curve; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:60:24 [INFO] [stdout] | [INFO] [stdout] 3 | let G = ECPoint::new(1.into_u256(), 1.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 3 | let G = ECPoint::new(1_i32.into_u256(), 1.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:60:39 [INFO] [stdout] | [INFO] [stdout] 3 | let G = ECPoint::new(1.into_u256(), 1.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 3 | let G = ECPoint::new(1.into_u256(), 1_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:61:36 [INFO] [stdout] | [INFO] [stdout] 4 | let curve = Curve::new(0.into(), 7.into_u256(), 11.into_u256(), 5.into_u256(), G); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let curve = Curve::new(0.into(), 7_i32.into_u256(), 11.into_u256(), 5.into_u256(), G); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:61:52 [INFO] [stdout] | [INFO] [stdout] 4 | let curve = Curve::new(0.into(), 7.into_u256(), 11.into_u256(), 5.into_u256(), G); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let curve = Curve::new(0.into(), 7.into_u256(), 11_i32.into_u256(), 5.into_u256(), G); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:61:67 [INFO] [stdout] | [INFO] [stdout] 4 | let curve = Curve::new(0.into(), 7.into_u256(), 11.into_u256(), 5.into_u256(), G); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let curve = Curve::new(0.into(), 7.into_u256(), 11.into_u256(), 5_i32.into_u256(), G); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:62:47 [INFO] [stdout] | [INFO] [stdout] 5 | let point = curve.scalar_multiply_generator(2.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let point = curve.scalar_multiply_generator(2_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error: aborting due to 8 previous errors [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0433, E0689. [INFO] [stdout] For more information about an error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_multiplication_scalar (line 185) stdout ---- [INFO] [stdout] error: unexpected token: `...` [INFO] [stdout] --> src/curves/elliptical_curve.rs:186:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] help: use `..` for an exclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] help: or `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..=; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0586]: inclusive range with no end [INFO] [stdout] --> src/curves/elliptical_curve.rs:186:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`) [INFO] [stdout] help: use `..` instead [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:188:22 [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:187:16 [INFO] [stdout] | [INFO] [stdout] 4 | let scalar = 2.into_u256(); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let scalar = 2_i32.into_u256(); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:188:37 [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5_i32.into_u256(), 7.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:188:52 [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error: aborting due to 6 previous errors [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0433, E0586, E0689. [INFO] [stdout] For more information about an error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_doubling (line 139) stdout ---- [INFO] [stdout] error: unexpected token: `...` [INFO] [stdout] --> src/curves/elliptical_curve.rs:140:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] help: use `..` for an exclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] help: or `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..=; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0586]: inclusive range with no end [INFO] [stdout] --> src/curves/elliptical_curve.rs:140:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`) [INFO] [stdout] help: use `..` instead [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:141:9 [INFO] [stdout] | [INFO] [stdout] 4 | let p = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:141:24 [INFO] [stdout] | [INFO] [stdout] 4 | let p = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let p = ECPoint::new(5_i32.into_u256(), 7.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:141:39 [INFO] [stdout] | [INFO] [stdout] 4 | let p = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let p = ECPoint::new(5.into_u256(), 7_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error: aborting due to 5 previous errors [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0433, E0586, E0689. [INFO] [stdout] For more information about an error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint::new (line 30) stdout ---- [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:31:13 [INFO] [stdout] | [INFO] [stdout] 3 | let point = ECPoint::new(5.into(), 7.into()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error: aborting due to 1 previous error [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint (line 13) stdout ---- [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:14:14 [INFO] [stdout] | [INFO] [stdout] 3 | let point1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:15:14 [INFO] [stdout] | [INFO] [stdout] 4 | let point2 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:14:29 [INFO] [stdout] | [INFO] [stdout] 3 | let point1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 3 | let point1 = ECPoint::new(5_i32.into_u256(), 7.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:14:44 [INFO] [stdout] | [INFO] [stdout] 3 | let point1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 3 | let point1 = ECPoint::new(5.into_u256(), 7_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:15:29 [INFO] [stdout] | [INFO] [stdout] 4 | let point2 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let point2 = ECPoint::new(5_i32.into_u256(), 7.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:15:44 [INFO] [stdout] | [INFO] [stdout] 4 | let point2 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let point2 = ECPoint::new(5.into_u256(), 7_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error: aborting due to 6 previous errors [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0433, E0689. [INFO] [stdout] For more information about an error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::add_points (line 92) stdout ---- [INFO] [stdout] error: unexpected token: `...` [INFO] [stdout] --> src/curves/elliptical_curve.rs:93:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] help: use `..` for an exclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] help: or `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..=; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0586]: inclusive range with no end [INFO] [stdout] --> src/curves/elliptical_curve.rs:93:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`) [INFO] [stdout] help: use `..` instead [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:94:10 [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:95:10 [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:94:25 [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5_i32.into_u256(), 7.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:94:40 [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let p1 = ECPoint::new(5.into_u256(), 7_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:95:25 [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3_i32.into_u256(), 2.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:95:40 [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let p2 = ECPoint::new(3.into_u256(), 2_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error: aborting due to 8 previous errors [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0433, E0586, E0689. [INFO] [stdout] For more information about an error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/number_mod/number_mod.rs - number_mod::number_mod::NumberUnderMod (line 31) stdout ---- [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `NumberUnderMod` [INFO] [stdout] --> src/number_mod/number_mod.rs:32:11 [INFO] [stdout] | [INFO] [stdout] 3 | let num = NumberUnderMod::new(10, 7); [INFO] [stdout] | ^^^^^^^^^^^^^^ use of undeclared type `NumberUnderMod` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::number_mod::NumberUnderMod; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error: aborting due to 1 previous error [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] ---- src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::scalar_multiply_generator (line 171) stdout ---- [INFO] [stdout] error: unexpected token: `...` [INFO] [stdout] --> src/curves/elliptical_curve.rs:172:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] help: use `..` for an exclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] help: or `..=` for an inclusive range [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..=; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0586]: inclusive range with no end [INFO] [stdout] --> src/curves/elliptical_curve.rs:172:13 [INFO] [stdout] | [INFO] [stdout] 3 | let curve = ...; // create a curve [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`) [INFO] [stdout] help: use `..` instead [INFO] [stdout] | [INFO] [stdout] 3 - let curve = ...; // create a curve [INFO] [stdout] 3 + let curve = ..; // create a curve [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared type `ECPoint` [INFO] [stdout] --> src/curves/elliptical_curve.rs:174:22 [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^ use of undeclared type `ECPoint` [INFO] [stdout] | [INFO] [stdout] help: consider importing this struct [INFO] [stdout] | [INFO] [stdout] 2 + use modular_math::curves::ECPoint; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:173:16 [INFO] [stdout] | [INFO] [stdout] 4 | let scalar = 2.into_u256(); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 4 | let scalar = 2_i32.into_u256(); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:174:37 [INFO] [stdout] | [INFO] [stderr] error: doctest failed, to rerun pass `--doc` [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5_i32.into_u256(), 7.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error[E0689]: can't call method `into_u256` on ambiguous numeric type `{integer}` [INFO] [stdout] --> src/curves/elliptical_curve.rs:174:52 [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7.into_u256()); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: you must specify a concrete type for this numeric value, like `i32` [INFO] [stdout] | [INFO] [stdout] 5 | let starting_point = ECPoint::new(5.into_u256(), 7_i32.into_u256()); [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] error: aborting due to 6 previous errors [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0433, E0586, E0689. [INFO] [stdout] For more information about an error, try `rustc --explain E0433`. [INFO] [stdout] Couldn't compile the test. [INFO] [stdout] [INFO] [stdout] failures: [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve (line 59) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::add_points (line 92) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_addition (line 110) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_doubling (line 139) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::point_multiplication_scalar (line 185) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::Curve::scalar_multiply_generator (line 171) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint (line 13) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint::eq (line 41) [INFO] [stdout] src/curves/elliptical_curve.rs - curves::elliptical_curve::ECPoint::new (line 30) [INFO] [stdout] src/number_mod/number_mod.rs - number_mod::number_mod::NumberUnderMod (line 31) [INFO] [stdout] [INFO] [stdout] test result: FAILED. 0 passed; 10 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.65s [INFO] [stdout] [INFO] running `Command { std: "docker" "inspect" "67714525b123dac4fb5b24636200955c459c5f86c1ee15ced5fc933769cf4c60", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "67714525b123dac4fb5b24636200955c459c5f86c1ee15ced5fc933769cf4c60", kill_on_drop: false }` [INFO] [stdout] 67714525b123dac4fb5b24636200955c459c5f86c1ee15ced5fc933769cf4c60