diff --git a/crates/solc-expressions/src/func_call/helper.rs b/crates/solc-expressions/src/func_call/helper.rs index e9bf44dd..346eb868 100644 --- a/crates/solc-expressions/src/func_call/helper.rs +++ b/crates/solc-expressions/src/func_call/helper.rs @@ -257,12 +257,12 @@ pub trait CallerHelper: AnalyzerBackend + tmp_literals[target_idx] = literals[i]; }); } else { - tmp_inputs = inputs.clone(); - tmp_literals = literals.clone(); + tmp_inputs.clone_from(&inputs); + tmp_literals.clone_from(&literals); } } else { - tmp_inputs = inputs.clone(); - tmp_literals = literals.clone(); + tmp_inputs.clone_from(&inputs); + tmp_literals.clone_from(&literals); } params diff --git a/crates/solc-expressions/src/literal.rs b/crates/solc-expressions/src/literal.rs index 76dc84fd..5a36a31e 100644 --- a/crates/solc-expressions/src/literal.rs +++ b/crates/solc-expressions/src/literal.rs @@ -842,7 +842,7 @@ mod tests { #[test] fn test_hex_literals_multiple() -> Result<()> { - let hex_literals = vec![ + let hex_literals = [ HexLiteral { hex: "7B".to_string(), // 123 in decimal loc: Loc::File(0, 0, 0),