error[E0080]: writing to ALLOC0 which is read-only --> $DIR/ptr_made_global_mutated.rs:10:5 | LL | *(ptr as *mut u8) = 2; | ^^^^^^^^^^^^^^^^^^^^^ evaluation of `A` failed here error: aborting due to 1 previous error For more information about this error, try `rustc --explain E0080`.