Fix unsafe_op_in_unsafe_fn in compiler
This commit is contained in:
parent
71eb49c318
commit
28503d69ac
15 changed files with 386 additions and 311 deletions
|
@ -33,7 +33,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);
|
||||
let slice = unsafe { slice::from_raw_parts(ptr as *const u8, size) };
|
||||
|
||||
sr.bytes.borrow_mut().extend_from_slice(slice);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue