diff options
Diffstat (limited to 'tests/ui/sanitizer/memory.rs')
| -rw-r--r-- | tests/ui/sanitizer/memory.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/ui/sanitizer/memory.rs b/tests/ui/sanitizer/memory.rs index bd2d6771749..a91fefe4d16 100644 --- a/tests/ui/sanitizer/memory.rs +++ b/tests/ui/sanitizer/memory.rs @@ -15,8 +15,8 @@ // since it will be linked with an uninstrumented version of it. #![feature(core_intrinsics)] -#![feature(start)] #![allow(invalid_value)] +#![no_main] use std::hint::black_box; use std::mem::MaybeUninit; @@ -39,8 +39,8 @@ fn xor(a: &[isize]) -> isize { s } -#[start] -fn main(_: isize, _: *const *const u8) -> isize { +#[no_mangle] +extern "C" fn main(_argc: std::ffi::c_int, _argv: *const *const u8) -> std::ffi::c_int { let r = black_box(random as fn() -> [isize; 32])(); - xor(&r) + xor(&r) as std::ffi::c_int } |
