Skip to content

Commit

Permalink
Rust: fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
mratsim committed Sep 25, 2024
1 parent b89135e commit 70fbcd9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ macro_rules! test_dir {
}

const AGGREGATE_VERIFY_TESTS: &str = concat!(test_dir!(), "aggregate_verify/*");
const AGGREGATE_TESTS: &str = concat!(test_dir!(), "aggregate/*");
// const AGGREGATE_TESTS: &str = concat!(test_dir!(), "aggregate/*");
const DESERIALIZATION_G1_TESTS: &str = concat!(test_dir!(), "deserialization_G1/*");
const BATCH_VERIFY_TESTS: &str = concat!(test_dir!(), "batch_verify/*");
const FAST_AGGREGATE_VERIFY_TESTS: &str = concat!(test_dir!(), "fast_aggregate_verify/*");
const HASH_TO_G2_TESTS: &str = concat!(test_dir!(), "hash_to_G2/*");
// const HASH_TO_G2_TESTS: &str = concat!(test_dir!(), "hash_to_G2/*");
const DESERIALIZATION_G2_TESTS: &str = concat!(test_dir!(), "deserialization_G2/*");
const VERIFY_TESTS: &str = concat!(test_dir!(), "verify/*");
const SIGN_TESTS: &str = concat!(test_dir!(), "sign/*");
Expand Down Expand Up @@ -294,7 +294,7 @@ fn t_sign() {
match skey {
Err(_e) => {
// empty output due to `null` JSON value
let (Some(tout), Some(tmsg)) =
let (Some(tout), Some(_)) =
(test.output.opt_bytes.0, test.input.message.opt_bytes.0)
else {
assert!(false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ const FAIL_MAP_FP2_TO_G2_BLS_TESTS: &str =

type HexString = String;

#[allow(dead_code, non_snake_case)]
#[derive(Deserialize, Debug)]
struct PrecompileTest {
Input: HexString,
Expand Down Expand Up @@ -238,17 +239,17 @@ fn t_map_fp_to_g1_bls_tests() {
t_generate(test_name, evm_bls12381_map_fp_to_g1);
}
#[test]
fn t_fail_map_fp_to_G1_bls_tests() {
fn t_fail_map_fp_to_g1_bls_tests() {
let test_name = FAIL_MAP_FP_TO_G1_BLS_TESTS.to_string();
t_generate(test_name, evm_bls12381_map_fp_to_g1);
}
#[test]
fn t_map_fp2_to_G2_bls_tests() {
fn t_map_fp2_to_g2_bls_tests() {
let test_name = MAP_FP2_TO_G2_BLS_TESTS.to_string();
t_generate(test_name, evm_bls12381_map_fp2_to_g2);
}
#[test]
fn t_fail_map_fp2_to_G2_bls_tests() {
fn t_fail_map_fp2_to_g2_bls_tests() {
let test_name = FAIL_MAP_FP2_TO_G2_BLS_TESTS.to_string();
t_generate(test_name, evm_bls12381_map_fp2_to_g2);
}

0 comments on commit 70fbcd9

Please sign in to comment.