rust/tests/mir-opt/ssa_unreachable_116212.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

16 lines
230 B
Rust
Raw Permalink Normal View History

// skip-filecheck
2023-09-28 12:05:52 -05:00
// Regression test for issue #116212.
#![feature(never_type)]
use std::mem::MaybeUninit;
struct Foo {
x: u8,
y: !,
}
fn main() {
let foo = unsafe { MaybeUninit::<Foo>::uninit().assume_init() };
}