about summary refs log tree commit diff
path: root/tests/ui/rfcs
diff options
context:
space:
mode:
authorBoxy <supbscripter@gmail.com>2024-06-04 09:10:08 +0100
committerBoxy <supbscripter@gmail.com>2024-06-05 22:25:42 +0100
commitf74119a2e4a5c040c054ebee1ae2ccda828fd21f (patch)
treef74f411f1cd0b38b54711cd64b8c9f845050abc7 /tests/ui/rfcs
parent7fa98d0c01050ee8c39bfc644d1414f5a21a1f21 (diff)
downloadrust-f74119a2e4a5c040c054ebee1ae2ccda828fd21f.tar.gz
rust-f74119a2e4a5c040c054ebee1ae2ccda828fd21f.zip
Bless tests and handle tests/crashes
Diffstat (limited to 'tests/ui/rfcs')
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.rs6
-rw-r--r--tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.stderr32
2 files changed, 14 insertions, 24 deletions
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.rs b/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.rs
index 9778217d462..6b5ba5bb624 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.rs
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.rs
@@ -17,8 +17,6 @@ impl<T> const Foo for T where T: const Specialize {}
 //~^ error: const `impl` for trait `Foo` which is not marked with `#[const_trait]`
 //~| error: `const` can only be applied to `#[const_trait]` traits
 //~| error: the const parameter `host` is not constrained by the impl trait, self type, or predicates [E0207]
-//~| error: specialization impl does not specialize any associated items
-//~| error: could not resolve generic parameters on overridden impl
+//~| error: conflicting implementations of trait `Foo`
 
-fn main() {
-}
+fn main() {}
diff --git a/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.stderr b/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.stderr
index d18063f8d3d..70dd0350dc4 100644
--- a/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.stderr
+++ b/tests/ui/rfcs/rfc-2632-const-trait-impl/effects/spec-effectvar-ice.stderr
@@ -37,6 +37,15 @@ LL | impl<T> const Foo for T {}
    = note: expressions using a const parameter must map each value to a distinct output value
    = note: proving the result of expressions other than the parameter are unique is not supported
 
+error[E0119]: conflicting implementations of trait `Foo`
+  --> $DIR/spec-effectvar-ice.rs:16:1
+   |
+LL | impl<T> const Foo for T {}
+   | ----------------------- first implementation here
+...
+LL | impl<T> const Foo for T where T: const Specialize {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation
+
 error[E0207]: the const parameter `host` is not constrained by the impl trait, self type, or predicates
   --> $DIR/spec-effectvar-ice.rs:16:9
    |
@@ -46,24 +55,7 @@ LL | impl<T> const Foo for T where T: const Specialize {}
    = note: expressions using a const parameter must map each value to a distinct output value
    = note: proving the result of expressions other than the parameter are unique is not supported
 
-error: specialization impl does not specialize any associated items
-  --> $DIR/spec-effectvar-ice.rs:16:1
-   |
-LL | impl<T> const Foo for T where T: const Specialize {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-note: impl is a specialization of this impl
-  --> $DIR/spec-effectvar-ice.rs:12:1
-   |
-LL | impl<T> const Foo for T {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^
-
-error: could not resolve generic parameters on overridden impl
-  --> $DIR/spec-effectvar-ice.rs:16:1
-   |
-LL | impl<T> const Foo for T where T: const Specialize {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: aborting due to 7 previous errors
+error: aborting due to 6 previous errors
 
-For more information about this error, try `rustc --explain E0207`.
+Some errors have detailed explanations: E0119, E0207.
+For more information about an error, try `rustc --explain E0119`.