1 error: Undefined Behavior: not granting access to tag <untagged> because incompatible item is protected: [SharedReadOnly for <TAG> (call ID)]
2 --> $DIR/invalidate_against_barrier2.rs:LL:CC
4 LL | unsafe { *x = 0 };
5 | ^^^^^^ not granting access to tag <untagged> because incompatible item is protected: [SharedReadOnly for <TAG> (call ID)]
7 = help: this indicates a potential bug in the program: it performed an invalid operation, but the Stacked Borrows rules it violated are still experimental
8 = help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
9 help: tag was most recently created at offsets [0x0..0x4]
10 --> $DIR/invalidate_against_barrier2.rs:LL:CC
12 LL | let xraw = &mut x as *mut _;
14 help: <TAG> was protected due to a tag which was created here
15 --> $DIR/invalidate_against_barrier2.rs:LL:CC
17 LL | inner(xraw, xref);
19 help: this protector is live for this call
20 --> $DIR/invalidate_against_barrier2.rs:LL:CC
22 LL | / fn inner(x: *mut i32, _y: &i32) {
23 LL | | // If `x` and `y` alias, retagging is fine with this... but we really
24 LL | | // shouldn't be allowed to write to `x` at all because `y` was assumed to be
25 LL | | // immutable for the duration of this call.
26 LL | | unsafe { *x = 0 };
29 = note: inside `inner` at $DIR/invalidate_against_barrier2.rs:LL:CC
30 note: inside `main` at $DIR/invalidate_against_barrier2.rs:LL:CC
31 --> $DIR/invalidate_against_barrier2.rs:LL:CC
33 LL | inner(xraw, xref);
36 note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
38 error: aborting due to previous error