]> git.lizzy.rs Git - rust.git/blob - src/test/ui/consts/dangling-alloc-id-ice.stderr
Rollup merge of #64603 - gilescope:unused-lifetime-warning, r=matthewjasper
[rust.git] / src / test / ui / consts / dangling-alloc-id-ice.stderr
1 error: any use of this value will cause an error
2   --> $DIR/dangling-alloc-id-ice.rs:8:1
3    |
4 LL | / const FOO: &() = {
5 LL | |     let y = ();
6 LL | |     unsafe { Foo { y: &y }.long_live_the_unit }
7 LL | | };
8    | |__^ type validation failed: encountered dangling pointer in final constant
9    |
10    = note: `#[deny(const_err)]` on by default
11
12 error: aborting due to previous error
13