blob: 616736bcf12ea6bd453afe214fd335baea0e6257 [file] [edit]
// Do not attempt to take the discriminant as the source
// converted to a `u128`, that won't work for ZST.
//
//@ compile-flags: -Zvalidate-mir
enum A {
B,
C,
}
fn main() {
let _: A = unsafe { std::mem::transmute(()) };
//~^ ERROR cannot transmute between types of different sizes, or dependently-sized types
}