From 4b4948c2e34e6b320f0091b97bf3044db467f4d3 Mon Sep 17 00:00:00 2001 From: Nilstrieb <48135649+Nilstrieb@users.noreply.github.com> Date: Sun, 9 Apr 2023 23:07:45 +0200 Subject: Remove identity casts --- compiler/rustc_llvm/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'compiler/rustc_llvm/src') diff --git a/compiler/rustc_llvm/src/lib.rs b/compiler/rustc_llvm/src/lib.rs index 8542dcf5bf0..ec3cf34d710 100644 --- a/compiler/rustc_llvm/src/lib.rs +++ b/compiler/rustc_llvm/src/lib.rs @@ -30,7 +30,7 @@ pub unsafe extern "C" fn LLVMRustStringWriteImpl( ptr: *const c_char, size: size_t, ) { - let slice = slice::from_raw_parts(ptr as *const u8, size as usize); + let slice = slice::from_raw_parts(ptr as *const u8, size); sr.bytes.borrow_mut().extend_from_slice(slice); } -- cgit 1.4.1-3-g733a5