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
(None, format!("pass the flag `-Zmiri-disable-isolation` to disable isolation;")),
158
157
(None, format!("or pass `-Zmiri-isolation-error=warn` to configure Miri to return an error code from isolated operations (if supported for that operation) and continue with a warning")),
159
158
],
160
-
ExperimentalUb{ url, help, history, .. } => {
159
+
StackedBorrowsUb{ help, history, .. } => {
160
+
let url = "https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md";
161
161
msg.extend(help.clone());
162
162
letmut helps = vec![
163
-
(None, format!("this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental")),
164
-
(None, format!("see {} for further information", url)),
163
+
(None, format!("this indicates a potential bug in the program: it performed an invalid operation, but the Stacked Borrows rules it violated are still experimental")),
164
+
(None, format!("see {url} for further information")),
Copy file name to clipboardexpand all lines: tests/fail/box-cell-alias.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | unsafe { (*ptr).set(20); }
7
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
8
| this error occurs as part of a reborrow at ALLOC[0x0..0x1]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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..0x1]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/alias_through_mutation.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _val = *target_alias;
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/aliasing_mut1.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ error: Undefined Behavior: not granting access to tag <TAG> because incompatible
4
4
LL | pub fn safe(_x: &mut i32, _y: &mut i32) {}
5
5
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not granting access to tag <TAG> because incompatible item is protected: [Unique for <TAG> (call ID)]
6
6
|
7
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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
8
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
9
9
help: <TAG> was created by a retag at offsets [0x0..0x4]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/aliasing_mut2.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ error: Undefined Behavior: not granting access to tag <TAG> because incompatible
4
4
LL | pub fn safe(_x: &i32, _y: &mut i32) {}
5
5
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not granting access to tag <TAG> because incompatible item is protected: [SharedReadOnly for <TAG> (call ID)]
6
6
|
7
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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
8
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
9
9
help: <TAG> was created by a retag at offsets [0x0..0x4]
| trying to reborrow <untagged> for SharedReadOnly permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of a reborrow at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/aliasing_mut4.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ error: Undefined Behavior: not granting access to tag <TAG> because incompatible
4
4
LL | pub fn safe(_x: &i32, _y: &mut Cell<i32>) {}
5
5
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ not granting access to tag <TAG> because incompatible item is protected: [SharedReadOnly for <TAG> (call ID)]
6
6
|
7
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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
8
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
9
9
help: <TAG> was created by a retag at offsets [0x0..0x4]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/box_exclusive_violation1.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | *our
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/buggy_as_mut_slice.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | v1[1] = 5;
7
7
| attempting a write access using <TAG> at ALLOC[0x4], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x4..0x8]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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..0xc]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/buggy_split_at_mut.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let (a, b) = safe::split_at_mut(&mut array, 0);
7
7
| trying to reborrow <TAG> for Unique permission at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of a reborrow at ALLOC[0x0..0x10]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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..0x10]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ deallocating while item is protected: [Unique for <TAG> (call ID)]
6
6
|
7
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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
8
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
9
9
10
10
= note: inside `std::alloc::dealloc` at RUSTLIB/alloc/src/alloc.rs:LL:CC
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ deallocating while item is protected: [SharedReadWrite for <TAG> (call ID)]
6
6
|
7
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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
8
= help: see https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md for further information
9
9
10
10
= note: inside `std::alloc::dealloc` at RUSTLIB/alloc/src/alloc.rs:LL:CC
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read1.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _val = *xref; // ...but any use of raw will invalidate our ref.
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read2.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _val = *xref; // ...but any use of raw will invalidate our ref.
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read3.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _val = *xref2;
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read4.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _illegal = *xref2;
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read5.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _val = *xref; // the mutable one is dead and gone
7
7
| attempting a read access using <TAG> at ALLOC[$HEX], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[$HEX..$HEX]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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 [$HEX..$HEX]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read6.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _val = *raw;
7
7
| attempting a read access using <untagged> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read7.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _val = *x.get_mut();
7
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
8
| this error occurs as part of a reborrow at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_read8.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _fail = *y1;
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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]
Copy file name to clipboardexpand all lines: tests/fail/stacked_borrows/illegal_write1.stderr
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ LL | let _x = *xref;
7
7
| attempting a read access using <TAG> at ALLOC[0x0], but that tag does not exist in the borrow stack for this location
8
8
| this error occurs as part of an access at ALLOC[0x0..0x4]
9
9
|
10
-
= help: this indicates a potential bug in the program: it performed an invalid operation, but the rules it violated are still experimental
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