test that MaybeUninit<bool> is not noundef
This commit is contained in:
parent
8cb0b6ca5b
commit
ced947fc12
@ -3,6 +3,8 @@
|
||||
#![crate_type = "lib"]
|
||||
#![feature(rustc_attrs)]
|
||||
|
||||
use std::mem::MaybeUninit;
|
||||
|
||||
pub struct S {
|
||||
_field: [i32; 8],
|
||||
}
|
||||
@ -17,6 +19,12 @@ pub fn boolean(x: bool) -> bool {
|
||||
x
|
||||
}
|
||||
|
||||
// CHECK: i8 @maybeuninit_boolean(i8 %x)
|
||||
#[no_mangle]
|
||||
pub fn maybeuninit_boolean(x: MaybeUninit<bool>) -> MaybeUninit<bool> {
|
||||
x
|
||||
}
|
||||
|
||||
// CHECK: @readonly_borrow(i32* noalias readonly align 4 dereferenceable(4) %_1)
|
||||
// FIXME #25759 This should also have `nocapture`
|
||||
#[no_mangle]
|
||||
|
Loading…
x
Reference in New Issue
Block a user