]> git.proxmox.com Git - rustc.git/blame - tests/ui/consts/const-eval/transmute-const-promotion.stderr
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / consts / const-eval / transmute-const-promotion.stderr
CommitLineData
48663c56 1error[E0716]: temporary value dropped while borrowed
5e7ed085 2 --> $DIR/transmute-const-promotion.rs:4:37
8faf50e0 3 |
b7449926 4LL | let x: &'static u32 = unsafe { &mem::transmute(3.0f32) };
487cf647 5 | ------------ ^^^^^^^^^^^^^^^^^^^^^^ creates a temporary value which is freed while still in use
48663c56
XL
6 | |
7 | type annotation requires that borrow lasts for `'static`
532ac7d7 8LL |
8faf50e0 9LL | }
48663c56 10 | - temporary value is freed at the end of this statement
8faf50e0
XL
11
12error: aborting due to previous error
13
48663c56 14For more information about this error, try `rustc --explain E0716`.