From d82a170351348608185da48e981a62402dbc3b53 Mon Sep 17 00:00:00 2001 From: Roy Ivy III Date: Thu, 26 Dec 2019 16:57:08 -0600 Subject: [PATCH] refactor/polish ~ fix `cargo clippy` complaints (allow unreadable_literal {for dynamic code}) --- src/cksum/build.rs | 2 +- src/factor/build.rs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cksum/build.rs b/src/cksum/build.rs index 37c48db5c..00c5c0fb4 100644 --- a/src/cksum/build.rs +++ b/src/cksum/build.rs @@ -30,7 +30,7 @@ fn main() { let file = File::create(&Path::new(&out_dir).join("crc_table.rs")).unwrap(); write!( &file, - "const CRC_TABLE: [u32; {}] = {:?};", + "#[allow(clippy::unreadable_literal)]\nconst CRC_TABLE: [u32; {}] = {:?};", CRC_TABLE_LEN, table ).unwrap(); } diff --git a/src/factor/build.rs b/src/factor/build.rs index 202be08b0..d1e73d5a2 100644 --- a/src/factor/build.rs +++ b/src/factor/build.rs @@ -149,5 +149,6 @@ const PREAMBLE: &'static str = r##"/* // Please do not edit by hand. Instead, modify and // re-run src/factor/gen_tables.rs. +#[allow(clippy::unreadable_literal)] pub const P_INVS_U64: &[(u64, u64, u64)] = &[ "##;