about summary refs log tree commit diff
diff options
context:
space:
mode:
authorJubilee <workingjubilee@gmail.com>2024-11-07 18:48:23 -0800
committerGitHub <noreply@github.com>2024-11-07 18:48:23 -0800
commit0683e031a857f51a7a4d05a6309fac09f8c8dd8f (patch)
treec998e81548ed3826cd3b7ca7477042e986ac075d
parent403647274938c76b29ef3edfa170701d927a2d41 (diff)
parentab1787b223c49b5e77519a0fe7f2bd648797f270 (diff)
downloadrust-0683e031a857f51a7a4d05a6309fac09f8c8dd8f.tar.gz
rust-0683e031a857f51a7a4d05a6309fac09f8c8dd8f.zip
Rollup merge of #132639 - RalfJung:intrinsics, r=workingjubilee,Amanieu
core: move intrinsics.rs into intrinsics folder

This makes the rustbot notification we have set up for this folder in `triagebot.toml` actually work. Also IMO it makes more sense to have it all in one folder.
-rw-r--r--library/core/src/intrinsics/mod.rs (renamed from library/core/src/intrinsics.rs)0
-rw-r--r--tests/ui/consts/const-eval/raw-pointer-ub.stderr4
-rw-r--r--tests/ui/intrinsics/const-eval-select-bad.stderr8
3 files changed, 6 insertions, 6 deletions
diff --git a/library/core/src/intrinsics.rs b/library/core/src/intrinsics/mod.rs
index d33a403cfda..d33a403cfda 100644
--- a/library/core/src/intrinsics.rs
+++ b/library/core/src/intrinsics/mod.rs
diff --git a/tests/ui/consts/const-eval/raw-pointer-ub.stderr b/tests/ui/consts/const-eval/raw-pointer-ub.stderr
index 3426a768cb6..c3360c8b3e2 100644
--- a/tests/ui/consts/const-eval/raw-pointer-ub.stderr
+++ b/tests/ui/consts/const-eval/raw-pointer-ub.stderr
@@ -11,12 +11,12 @@ LL |     *ptr = 0;
    |     ^^^^^^^^ accessing memory based on pointer with alignment 1, but alignment 4 is required
 
 error[E0080]: evaluation of constant value failed
-  --> $SRC_DIR/core/src/intrinsics.rs:LL:COL
+  --> $SRC_DIR/core/src/intrinsics/mod.rs:LL:COL
    |
    = note: accessing memory with alignment 1, but alignment 4 is required
    |
 note: inside `copy_nonoverlapping::<u32>`
-  --> $SRC_DIR/core/src/intrinsics.rs:LL:COL
+  --> $SRC_DIR/core/src/intrinsics/mod.rs:LL:COL
 note: inside `std::ptr::const_ptr::<impl *const u32>::copy_to_nonoverlapping`
   --> $SRC_DIR/core/src/ptr/const_ptr.rs:LL:COL
 note: inside `MISALIGNED_COPY`
diff --git a/tests/ui/intrinsics/const-eval-select-bad.stderr b/tests/ui/intrinsics/const-eval-select-bad.stderr
index 50092edda4f..e317ed23ab1 100644
--- a/tests/ui/intrinsics/const-eval-select-bad.stderr
+++ b/tests/ui/intrinsics/const-eval-select-bad.stderr
@@ -27,7 +27,7 @@ LL |     const_eval_select((), 42, 0xDEADBEEF);
    = help: the trait `FnOnce()` is not implemented for `{integer}`
    = note: wrap the `{integer}` in a closure with no arguments: `|| { /* code */ }`
 note: required by a bound in `const_eval_select`
-  --> $SRC_DIR/core/src/intrinsics.rs:LL:COL
+  --> $SRC_DIR/core/src/intrinsics/mod.rs:LL:COL
 
 error[E0277]: expected a `FnOnce()` closure, found `{integer}`
   --> $DIR/const-eval-select-bad.rs:10:31
@@ -40,7 +40,7 @@ LL |     const_eval_select((), 42, 0xDEADBEEF);
    = help: the trait `FnOnce()` is not implemented for `{integer}`
    = note: wrap the `{integer}` in a closure with no arguments: `|| { /* code */ }`
 note: required by a bound in `const_eval_select`
-  --> $SRC_DIR/core/src/intrinsics.rs:LL:COL
+  --> $SRC_DIR/core/src/intrinsics/mod.rs:LL:COL
 
 error: this argument must be a function item
   --> $DIR/const-eval-select-bad.rs:10:27
@@ -69,7 +69,7 @@ LL |     const_eval_select((1,), foo, bar);
    |     required by a bound introduced by this call
    |
 note: required by a bound in `const_eval_select`
-  --> $SRC_DIR/core/src/intrinsics.rs:LL:COL
+  --> $SRC_DIR/core/src/intrinsics/mod.rs:LL:COL
 
 error[E0631]: type mismatch in function arguments
   --> $DIR/const-eval-select-bad.rs:37:32
@@ -85,7 +85,7 @@ LL |     const_eval_select((true,), foo, baz);
    = note: expected function signature `fn(bool) -> _`
               found function signature `fn(i32) -> _`
 note: required by a bound in `const_eval_select`
-  --> $SRC_DIR/core/src/intrinsics.rs:LL:COL
+  --> $SRC_DIR/core/src/intrinsics/mod.rs:LL:COL
 help: consider wrapping the function in a closure
    |
 LL |     const_eval_select((true,), |arg0: bool| foo(/* i32 */), baz);