Skip to content

Commit

Permalink
Fix unused borrow warning
Browse files Browse the repository at this point in the history
`#[warn(unused_must_use)]` is on, prompting a compiler warning like:
"unused borrow that must be used".
  • Loading branch information
abrown committed Jul 28, 2021
1 parent 323197e commit e3c56ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/debug/src/transform/expression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ impl CompiledExpression {
let new_to = landing_positions[&marker];
let new_diff = new_to as isize - new_from as isize;
// FIXME: use encoding? LittleEndian for now...
&code_buf[new_from - 2..new_from]
code_buf[new_from - 2..new_from]
.copy_from_slice(&(new_diff as i16).to_le_bytes());
}
Ok(Some((func_index, start, end, code_buf)))
Expand Down

0 comments on commit e3c56ef

Please sign in to comment.