diff options
Diffstat (limited to 'src/tools/miri/tests/fail/tree-borrows/read-to-local.stderr')
-rw-r--r-- | src/tools/miri/tests/fail/tree-borrows/read-to-local.stderr | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/src/tools/miri/tests/fail/tree-borrows/read-to-local.stderr b/src/tools/miri/tests/fail/tree-borrows/read-to-local.stderr index 7d9367c87d0..8c9c2f8f965 100644 --- a/src/tools/miri/tests/fail/tree-borrows/read-to-local.stderr +++ b/src/tools/miri/tests/fail/tree-borrows/read-to-local.stderr @@ -1,12 +1,31 @@ -error: Undefined Behavior: write access through <TAG> is forbidden because it is a child of <TAG> which is Frozen. +error: Undefined Behavior: write access through <TAG> is forbidden --> $DIR/read-to-local.rs:LL:CC | LL | *ptr = 0; - | ^^^^^^^^ write access through <TAG> is forbidden because it is a child of <TAG> which is Frozen. + | ^^^^^^^^ write access through <TAG> is forbidden | = help: this indicates a potential bug in the program: it performed an invalid operation, but the Tree Borrows rules it violated are still experimental - = note: BACKTRACE: + = help: the accessed tag <TAG> has state Frozen which forbids child write accesses +help: the accessed tag <TAG> was created here, in the initial state Reserved + --> $DIR/read-to-local.rs:LL:CC + | +LL | let mref = &mut root; + | ^^^^^^^^^ +help: the accessed tag <TAG> then transitioned from Reserved to Active due to a child write access at offsets [0x0..0x1] + --> $DIR/read-to-local.rs:LL:CC + | +LL | *ptr = 0; // Write + | ^^^^^^^^ + = help: this corresponds to an activation +help: the accessed tag <TAG> then transitioned from Active to Frozen due to a foreign read access at offsets [0x0..0x1] + --> $DIR/read-to-local.rs:LL:CC + | +LL | assert_eq!(root, 0); // Parent Read + | ^^^^^^^^^^^^^^^^^^^ + = help: this corresponds to a loss of write permissions + = note: BACKTRACE (of the first span): = note: inside `main` at $DIR/read-to-local.rs:LL:CC + = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info) note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace |