error: encountered dangling pointer in final value of constant | |
--> $DIR/dealloc_intrinsic_dangling.rs:7:1 | |
| | |
LL | const _X: &'static u8 = unsafe { | |
| ^^^^^^^^^^^^^^^^^^^^^ | |
error[E0080]: evaluation of constant value failed | |
--> $DIR/dealloc_intrinsic_dangling.rs:18:5 | |
| | |
LL | *reference | |
| ^^^^^^^^^^ memory access failed: ALLOC0 has been freed, so this pointer is dangling | |
error: aborting due to 2 previous errors | |
For more information about this error, try `rustc --explain E0080`. |