You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tests/fail/stacked_borrows/interior_mut2.stderr
+9-9
Original file line number
Diff line number
Diff line change
@@ -1,24 +1,24 @@
1
1
error: Undefined Behavior: trying to reborrow <TAG> for SharedReadWrite permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
2
2
--> $DIR/interior_mut2.rs:LL:CC
3
3
|
4
-
LL | let _val = *inner_shr.get();
5
-
| ^^^^^^^^^^^^^^^
6
-
| |
7
-
| trying to reborrow <TAG> for SharedReadWrite permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
-
| this error occurs as part of a reborrow at ALLOC[0x0..0x4]
4
+
LL | let _val = *inner_shr.get();
5
+
| ^^^^^^^^^^^^^^^
6
+
| |
7
+
| trying to reborrow <TAG> for SharedReadWrite permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
+
| this error occurs as part of a reborrow at ALLOC[0x0..0x4]
9
9
|
10
10
= help: this indicates a potential bug in the program: it performed an invalid operation, but the Stacked Borrows rules it violated are still experimental
11
11
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
12
12
help: <TAG> was created by a retag at offsets [0x0..0x4]
13
13
--> $DIR/interior_mut2.rs:LL:CC
14
14
|
15
-
LL | let inner_shr = &*inner_uniq;
16
-
| ^^^^^^^^^^^^
15
+
LL | let inner_shr = &*inner_uniq;
16
+
| ^^^^^^^^^^^^
17
17
help: <TAG> was later invalidated at offsets [0x0..0x4]
18
18
--> $DIR/interior_mut2.rs:LL:CC
19
19
|
20
-
LL | *c.get() = UnsafeCell::new(0); // now inner_shr gets invalidated
21
-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
20
+
LL | *c.get() = UnsafeCell::new(0); // now inner_shr gets invalidated
21
+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
22
22
= note: inside `main` at $DIR/interior_mut2.rs:LL:CC
23
23
24
24
note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
Copy file name to clipboardExpand all lines: tests/fail/stacked_borrows/mut_exclusive_violation1.stderr
+11-11
Original file line number
Diff line number
Diff line change
@@ -1,30 +1,30 @@
1
1
error: Undefined Behavior: attempting a write access using <untagged> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
2
2
--> $DIR/mut_exclusive_violation1.rs:LL:CC
3
3
|
4
-
LL | *LEAK = 7;
5
-
| ^^^^^^^^^
6
-
| |
7
-
| attempting a write access using <untagged> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
-
| this error occurs as part of an access at ALLOC[0x0..0x4]
4
+
LL | *LEAK = 7;
5
+
| ^^^^^^^^^
6
+
| |
7
+
| attempting a write access using <untagged> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
+
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
10
= help: this indicates a potential bug in the program: it performed an invalid operation, but the Stacked Borrows rules it violated are still experimental
11
11
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
12
12
help: tag was most recently created at offsets [0x0..0x4]
13
13
--> $DIR/mut_exclusive_violation1.rs:LL:CC
14
14
|
15
-
LL | LEAK = x as *const _ as *mut _;
16
-
| ^
15
+
LL | LEAK = x as *const _ as *mut _;
16
+
| ^
17
17
help: tag was later invalidated at offsets [0x0..0x4]
18
18
--> $DIR/mut_exclusive_violation1.rs:LL:CC
19
19
|
20
-
LL | *our = 5;
21
-
| ^^^^^^^^
20
+
LL | *our = 5;
21
+
| ^^^^^^^^
22
22
= note: inside `unknown_code_2` at $DIR/mut_exclusive_violation1.rs:LL:CC
23
23
note: inside `demo_mut_advanced_unique` at $DIR/mut_exclusive_violation1.rs:LL:CC
24
24
--> $DIR/mut_exclusive_violation1.rs:LL:CC
25
25
|
26
-
LL | unknown_code_2();
27
-
| ^^^^^^^^^^^^^^^^
26
+
LL | unknown_code_2();
27
+
| ^^^^^^^^^^^^^^^^
28
28
note: inside `main` at $DIR/mut_exclusive_violation1.rs:LL:CC
Copy file name to clipboardExpand all lines: tests/fail/stacked_borrows/mut_exclusive_violation2.stderr
+9-9
Original file line number
Diff line number
Diff line change
@@ -1,24 +1,24 @@
1
1
error: Undefined Behavior: attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
2
2
--> $DIR/mut_exclusive_violation2.rs:LL:CC
3
3
|
4
-
LL | let _val = *raw1;
5
-
| ^^^^^
6
-
| |
7
-
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
-
| this error occurs as part of an access at ALLOC[0x0..0x4]
4
+
LL | let _val = *raw1;
5
+
| ^^^^^
6
+
| |
7
+
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
+
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
10
= help: this indicates a potential bug in the program: it performed an invalid operation, but the Stacked Borrows rules it violated are still experimental
11
11
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
12
12
help: <TAG> was created by a retag at offsets [0x0..0x4]
13
13
--> $DIR/mut_exclusive_violation2.rs:LL:CC
14
14
|
15
-
LL | let raw1 = ptr1.as_mut();
16
-
| ^^^^^^^^^^^^^
15
+
LL | let raw1 = ptr1.as_mut();
16
+
| ^^^^^^^^^^^^^
17
17
help: <TAG> was later invalidated at offsets [0x0..0x4]
18
18
--> $DIR/mut_exclusive_violation2.rs:LL:CC
19
19
|
20
-
LL | let _raw2 = ptr2.as_mut();
21
-
| ^^^^^^^^^^^^^
20
+
LL | let _raw2 = ptr2.as_mut();
21
+
| ^^^^^^^^^^^^^
22
22
= note: inside `main` at $DIR/mut_exclusive_violation2.rs:LL:CC
23
23
24
24
note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
Copy file name to clipboardExpand all lines: tests/fail/stacked_borrows/return_invalid_mut_option.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
error: Undefined Behavior: trying to reborrow <TAG> for Unique permission at ALLOC[0x4], but that tag does not exist in the borrow stack for this location
2
2
--> $DIR/return_invalid_mut_option.rs:LL:CC
3
3
|
4
-
LL | Some(_x) => {},
4
+
LL | Some(_x) => {}
5
5
| ^^
6
6
| |
7
7
| trying to reborrow <TAG> for Unique permission at ALLOC[0x4], but that tag does not exist in the borrow stack for this location
Copy file name to clipboardExpand all lines: tests/fail/stacked_borrows/return_invalid_shr_option.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
error: Undefined Behavior: trying to reborrow <TAG> for SharedReadOnly permission at ALLOC[0x4], but that tag does not exist in the borrow stack for this location
2
2
--> $DIR/return_invalid_shr_option.rs:LL:CC
3
3
|
4
-
LL | Some(_x) => {},
4
+
LL | Some(_x) => {}
5
5
| ^^
6
6
| |
7
7
| trying to reborrow <TAG> for SharedReadOnly permission at ALLOC[0x4], but that tag does not exist in the borrow stack for this location
Copy file name to clipboardExpand all lines: tests/fail/stacked_borrows/shared_rw_borrows_are_weak1.stderr
+9-9
Original file line number
Diff line number
Diff line change
@@ -1,24 +1,24 @@
1
1
error: Undefined Behavior: trying to reborrow <TAG> for SharedReadWrite permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
2
2
--> $DIR/shared_rw_borrows_are_weak1.rs:LL:CC
3
3
|
4
-
LL | y.get_mut();
5
-
| ^^^^^^^^^^^
6
-
| |
7
-
| trying to reborrow <TAG> for SharedReadWrite permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
-
| this error occurs as part of a reborrow at ALLOC[0x0..0x4]
4
+
LL | y.get_mut();
5
+
| ^^^^^^^^^^^
6
+
| |
7
+
| trying to reborrow <TAG> for SharedReadWrite permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
+
| this error occurs as part of a reborrow at ALLOC[0x0..0x4]
9
9
|
10
10
= help: this indicates a potential bug in the program: it performed an invalid operation, but the Stacked Borrows rules it violated are still experimental
11
11
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
12
12
help: <TAG> was created by a retag at offsets [0x0..0x4]
0 commit comments