Skip to content

Commit

Permalink
Remove unnecessary cast in cabi_dealloc (#991)
Browse files Browse the repository at this point in the history
  • Loading branch information
andrzejressel authored Jul 8, 2024
1 parent 396d2e7 commit 7af0f81
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/rust/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ pub unsafe fn cabi_dealloc(ptr: *mut u8, size: usize, align: usize) {
return;
}
let layout = alloc::Layout::from_size_align_unchecked(size, align);
alloc::dealloc(ptr as *mut u8, layout);
alloc::dealloc(ptr, layout);
}
",
);
Expand Down

0 comments on commit 7af0f81

Please sign in to comment.