summaryrefslogtreecommitdiffstats
path: root/tests/ui/const-generics/issues
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-07 05:48:48 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-07 05:48:48 +0000
commitef24de24a82fe681581cc130f342363c47c0969a (patch)
tree0d494f7e1a38b95c92426f58fe6eaa877303a86c /tests/ui/const-generics/issues
parentReleasing progress-linux version 1.74.1+dfsg1-1~progress7.99u1. (diff)
downloadrustc-ef24de24a82fe681581cc130f342363c47c0969a.tar.xz
rustc-ef24de24a82fe681581cc130f342363c47c0969a.zip
Merging upstream version 1.75.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/const-generics/issues')
-rw-r--r--tests/ui/const-generics/issues/issue-100313.stderr2
-rw-r--r--tests/ui/const-generics/issues/issue-67945-1.full.stderr2
-rw-r--r--tests/ui/const-generics/issues/issue-74950.min.stderr4
-rw-r--r--tests/ui/const-generics/issues/issue-83249.stderr15
4 files changed, 18 insertions, 5 deletions
diff --git a/tests/ui/const-generics/issues/issue-100313.stderr b/tests/ui/const-generics/issues/issue-100313.stderr
index 796966b22..5832dbe17 100644
--- a/tests/ui/const-generics/issues/issue-100313.stderr
+++ b/tests/ui/const-generics/issues/issue-100313.stderr
@@ -11,7 +11,7 @@ error[E0080]: evaluation of constant value failed
--> $DIR/issue-100313.rs:10:13
|
LL | *(B as *const bool as *mut bool) = false;
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ writing to alloc7 which is read-only
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ writing to ALLOC0 which is read-only
|
note: inside `T::<&true>::set_false`
--> $DIR/issue-100313.rs:10:13
diff --git a/tests/ui/const-generics/issues/issue-67945-1.full.stderr b/tests/ui/const-generics/issues/issue-67945-1.full.stderr
index 8879aec35..ee17ec3c6 100644
--- a/tests/ui/const-generics/issues/issue-67945-1.full.stderr
+++ b/tests/ui/const-generics/issues/issue-67945-1.full.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
--> $DIR/issue-67945-1.rs:10:20
|
LL | struct Bug<S> {
- | - this type parameter
+ | - expected this type parameter
...
LL | let x: S = MaybeUninit::uninit();
| - ^^^^^^^^^^^^^^^^^^^^^ expected type parameter `S`, found `MaybeUninit<_>`
diff --git a/tests/ui/const-generics/issues/issue-74950.min.stderr b/tests/ui/const-generics/issues/issue-74950.min.stderr
index a5dbe10b7..54ef1ea1e 100644
--- a/tests/ui/const-generics/issues/issue-74950.min.stderr
+++ b/tests/ui/const-generics/issues/issue-74950.min.stderr
@@ -15,6 +15,7 @@ LL | struct Outer<const I: Inner>;
|
= note: the only supported types are integers, `bool` and `char`
= help: add `#![feature(adt_const_params)]` to the crate attributes to enable more complex and user defined types
+ = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `Inner` is forbidden as the type of a const generic parameter
--> $DIR/issue-74950.rs:20:23
@@ -24,6 +25,7 @@ LL | struct Outer<const I: Inner>;
|
= note: the only supported types are integers, `bool` and `char`
= help: add `#![feature(adt_const_params)]` to the crate attributes to enable more complex and user defined types
+ = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `Inner` is forbidden as the type of a const generic parameter
--> $DIR/issue-74950.rs:20:23
@@ -33,6 +35,7 @@ LL | struct Outer<const I: Inner>;
|
= note: the only supported types are integers, `bool` and `char`
= help: add `#![feature(adt_const_params)]` to the crate attributes to enable more complex and user defined types
+ = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: `Inner` is forbidden as the type of a const generic parameter
--> $DIR/issue-74950.rs:20:23
@@ -42,6 +45,7 @@ LL | struct Outer<const I: Inner>;
|
= note: the only supported types are integers, `bool` and `char`
= help: add `#![feature(adt_const_params)]` to the crate attributes to enable more complex and user defined types
+ = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: aborting due to 5 previous errors
diff --git a/tests/ui/const-generics/issues/issue-83249.stderr b/tests/ui/const-generics/issues/issue-83249.stderr
index 7491fdc8a..5187434ff 100644
--- a/tests/ui/const-generics/issues/issue-83249.stderr
+++ b/tests/ui/const-generics/issues/issue-83249.stderr
@@ -1,9 +1,18 @@
-error[E0282]: type annotations needed
+error[E0283]: type annotations needed
--> $DIR/issue-83249.rs:19:9
|
LL | let _ = foo([0; 1]);
- | ^
+ | ^ --- ------ type must be known at this point
+ | |
+ | required by a bound introduced by this call
|
+ = note: cannot satisfy `_: Foo`
+ = help: the trait `Foo` is implemented for `u8`
+note: required by a bound in `foo`
+ --> $DIR/issue-83249.rs:12:11
+ |
+LL | fn foo<T: Foo>(_: [u8; T::N]) -> T {
+ | ^^^ required by this bound in `foo`
help: consider giving this pattern a type
|
LL | let _: /* Type */ = foo([0; 1]);
@@ -11,4 +20,4 @@ LL | let _: /* Type */ = foo([0; 1]);
error: aborting due to previous error
-For more information about this error, try `rustc --explain E0282`.
+For more information about this error, try `rustc --explain E0283`.