2023-12-24 04:09:58 -06:00
|
|
|
//@ run-pass
|
2023-12-27 16:11:58 -06:00
|
|
|
struct NoDerive(#[allow(dead_code)] i32);
|
2023-12-24 04:09:58 -06:00
|
|
|
|
|
|
|
#[derive(PartialEq)]
|
|
|
|
struct WrapEmbedded(*const NoDerive);
|
|
|
|
|
|
|
|
const WRAP_UNSAFE_EMBEDDED: &&WrapEmbedded = &&WrapEmbedded(std::ptr::null());
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let b = match WRAP_UNSAFE_EMBEDDED {
|
|
|
|
WRAP_UNSAFE_EMBEDDED => true,
|
|
|
|
_ => false,
|
|
|
|
};
|
|
|
|
assert!(b);
|
|
|
|
}
|