summaryrefslogtreecommitdiffstats
path: root/src/test/ui/consts/extra-const-ub/detect-extra-ub.with_flag.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/consts/extra-const-ub/detect-extra-ub.with_flag.stderr')
-rw-r--r--src/test/ui/consts/extra-const-ub/detect-extra-ub.with_flag.stderr27
1 files changed, 15 insertions, 12 deletions
diff --git a/src/test/ui/consts/extra-const-ub/detect-extra-ub.with_flag.stderr b/src/test/ui/consts/extra-const-ub/detect-extra-ub.with_flag.stderr
index 3e1195822..2603a7358 100644
--- a/src/test/ui/consts/extra-const-ub/detect-extra-ub.with_flag.stderr
+++ b/src/test/ui/consts/extra-const-ub/detect-extra-ub.with_flag.stderr
@@ -32,27 +32,30 @@ error[E0080]: evaluation of constant value failed
--> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
|
LL | copy_nonoverlapping(src, tmp.as_mut_ptr(), 1);
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- | |
- | accessing memory with alignment 1, but alignment 4 is required
- | inside `std::ptr::read::<u32>` at $SRC_DIR/core/src/ptr/mod.rs:LL:COL
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ accessing memory with alignment 1, but alignment 4 is required
|
- ::: $SRC_DIR/core/src/ptr/const_ptr.rs:LL:COL
+note: inside `std::ptr::read::<u32>`
+ --> $SRC_DIR/core/src/ptr/mod.rs:LL:COL
|
-LL | unsafe { read(self) }
- | ---------- inside `ptr::const_ptr::<impl *const u32>::read` at $SRC_DIR/core/src/ptr/const_ptr.rs:LL:COL
+LL | copy_nonoverlapping(src, tmp.as_mut_ptr(), 1);
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+note: inside `ptr::const_ptr::<impl *const u32>::read`
+ --> $SRC_DIR/core/src/ptr/const_ptr.rs:LL:COL
|
- ::: $DIR/detect-extra-ub.rs:38:9
+LL | unsafe { read(self) }
+ | ^^^^^^^^^^
+note: inside `INNER`
+ --> $DIR/detect-extra-ub.rs:38:9
|
LL | ptr.read();
- | ---------- inside `INNER` at $DIR/detect-extra-ub.rs:38:9
+ | ^^^^^^^^^^
-error[E0080]: evaluation of constant value failed
+note: erroneous constant used
--> $DIR/detect-extra-ub.rs:32:5
|
LL | INNER;
- | ^^^^^ referenced constant has errors
+ | ^^^^^
-error: aborting due to 6 previous errors
+error: aborting due to 5 previous errors
For more information about this error, try `rustc --explain E0080`.