about summary refs log tree commit diff
path: root/tests/ui/impl-trait
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/impl-trait')
-rw-r--r--tests/ui/impl-trait/in-trait/refine-resolution-errors.rs1
-rw-r--r--tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr11
-rw-r--r--tests/ui/impl-trait/issues/issue-87340.rs2
-rw-r--r--tests/ui/impl-trait/issues/issue-87340.stderr17
4 files changed, 4 insertions, 27 deletions
diff --git a/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs b/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs
index a9936c7bc3f..894f592d9e2 100644
--- a/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs
+++ b/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs
@@ -13,7 +13,6 @@ impl<T: ?Sized> Mirror for () {
 
 pub trait First {
     async fn first() -> <() as Mirror>::Assoc;
-    //~^ ERROR type annotations needed
 }
 
 impl First for () {
diff --git a/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr b/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr
index 0f5573dda04..10ebad2a7d5 100644
--- a/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr
+++ b/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr
@@ -4,13 +4,6 @@ error[E0207]: the type parameter `T` is not constrained by the impl trait, self
 LL | impl<T: ?Sized> Mirror for () {
    |      ^ unconstrained type parameter
 
-error[E0282]: type annotations needed
-  --> $DIR/refine-resolution-errors.rs:15:5
-   |
-LL |     async fn first() -> <() as Mirror>::Assoc;
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ cannot infer type
-
-error: aborting due to 2 previous errors
+error: aborting due to 1 previous error
 
-Some errors have detailed explanations: E0207, E0282.
-For more information about an error, try `rustc --explain E0207`.
+For more information about this error, try `rustc --explain E0207`.
diff --git a/tests/ui/impl-trait/issues/issue-87340.rs b/tests/ui/impl-trait/issues/issue-87340.rs
index b1baaaa6ba5..705a4addcb7 100644
--- a/tests/ui/impl-trait/issues/issue-87340.rs
+++ b/tests/ui/impl-trait/issues/issue-87340.rs
@@ -9,8 +9,6 @@ impl<T> X for () {
     //~^ ERROR `T` is not constrained by the impl trait, self type, or predicates
     type I = impl Sized;
     fn f() -> Self::I {}
-    //~^ ERROR type annotations needed
-    //~| ERROR type annotations needed
 }
 
 fn main() {}
diff --git a/tests/ui/impl-trait/issues/issue-87340.stderr b/tests/ui/impl-trait/issues/issue-87340.stderr
index 1be4087be42..8513cb2881e 100644
--- a/tests/ui/impl-trait/issues/issue-87340.stderr
+++ b/tests/ui/impl-trait/issues/issue-87340.stderr
@@ -4,19 +4,6 @@ error[E0207]: the type parameter `T` is not constrained by the impl trait, self
 LL | impl<T> X for () {
    |      ^ unconstrained type parameter
 
-error[E0282]: type annotations needed
-  --> $DIR/issue-87340.rs:11:23
-   |
-LL |     fn f() -> Self::I {}
-   |                       ^^ cannot infer type for type parameter `T`
-
-error[E0282]: type annotations needed
-  --> $DIR/issue-87340.rs:11:15
-   |
-LL |     fn f() -> Self::I {}
-   |               ^^^^^^^ cannot infer type for type parameter `T`
-
-error: aborting due to 3 previous errors
+error: aborting due to 1 previous error
 
-Some errors have detailed explanations: E0207, E0282.
-For more information about an error, try `rustc --explain E0207`.
+For more information about this error, try `rustc --explain E0207`.