Clippy fixes

This commit is contained in:
Brian Carroll 2022-01-09 16:41:53 +00:00
parent 4f15fb3967
commit dd79a9b35a
3 changed files with 3 additions and 2 deletions

View file

@ -57,6 +57,7 @@ pub struct WasmBackend<'a> {
} }
impl<'a> WasmBackend<'a> { impl<'a> WasmBackend<'a> {
#[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
env: &'a Env<'a>, env: &'a Env<'a>,
interns: &'a mut Interns, interns: &'a mut Interns,

View file

@ -233,5 +233,5 @@ pub const DEBUG_LOG_SETTINGS: WasmDebugLogSettings = WasmDebugLogSettings {
helper_procs_ir: false && cfg!(debug_assertions), helper_procs_ir: false && cfg!(debug_assertions),
let_stmt_ir: false && cfg!(debug_assertions), let_stmt_ir: false && cfg!(debug_assertions),
instructions: false && cfg!(debug_assertions), instructions: false && cfg!(debug_assertions),
keep_test_binary: false && cfg!(debug_assertions), keep_test_binary: true && cfg!(debug_assertions),
}; };

View file

@ -117,7 +117,7 @@ impl<'a> WasmModule<'a> {
pub fn preload(arena: &'a Bump, bytes: &[u8]) -> Self { pub fn preload(arena: &'a Bump, bytes: &[u8]) -> Self {
let is_valid_magic_number = &bytes[0..4] == "\0asm".as_bytes(); let is_valid_magic_number = &bytes[0..4] == "\0asm".as_bytes();
let is_valid_version = &bytes[4..8] == Self::WASM_VERSION.to_le_bytes(); let is_valid_version = bytes[4..8] == Self::WASM_VERSION.to_le_bytes();
if !is_valid_magic_number || !is_valid_version { if !is_valid_magic_number || !is_valid_version {
internal_error!("Invalid Wasm object file header for platform & builtins"); internal_error!("Invalid Wasm object file header for platform & builtins");
} }