1 #![feature(const_fn, const_fn_union)]
10 const fn bar() -> u8 {
12 // This will error as long as this test is run on a system whose
13 // pointers need more than 8 bits.
14 Bar { a: &42 }.b as u8
19 // This will compile, but then hard-abort at runtime.
20 // FIXME(oli-obk): this should instead panic (not hard-abort) at runtime.
21 let x: &'static u8 = &(bar() + 1);
22 //~^ ERROR temporary value dropped while borrowed