Skip to content

Commit

Permalink
perf: remove unnecessary to_vec (matter-labs#702)
Browse files Browse the repository at this point in the history
## What ❔

Remove unnecessary method call

## Why ❔

It might improve performance but probably not. Better to not have it
anyway.
  • Loading branch information
joonazan authored Dec 18, 2023
1 parent 9f096a4 commit c55a658
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion core/lib/utils/src/misc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ pub fn expand_memory_contents(packed: &[(usize, U256)], memory_size_bytes: usize
value.to_big_endian(&mut result[(offset * 32)..(offset + 1) * 32]);
}

result.to_vec()
result
}

#[cfg(test)]
Expand Down

0 comments on commit c55a658

Please sign in to comment.