]> git.lizzy.rs Git - rust.git/blobdiff - src/test/ui/generic-associated-types/construct_with_other_type.stderr
bootstrap: Configurable musl libdir
[rust.git] / src / test / ui / generic-associated-types / construct_with_other_type.stderr
index f27bc4d68d441751ee4fae46391fbc5bfb5f44c8..b9468b3330b44e5b4a794fe2a7b2824b837dbe34 100644 (file)
@@ -1,19 +1,17 @@
 error[E0271]: type mismatch resolving `for<'a> <<T as Baz>::Baa<'a> as std::ops::Deref>::Target == <<T as Baz>::Quux<'a> as Foo>::Bar<'a, 'static>`
   --> $DIR/construct_with_other_type.rs:19:9
    |
-LL | trait Baz {
-   |       ---
-...
-LL |     type Baa<'a>: Deref<Target = <Self::Quux<'a> as Foo>::Bar<'a, 'static>>  where Self: 'a;
-   |                         -------------------------------------------------- required by this bound in `Baz`
-...
 LL | impl<T> Baz for T where T: Foo {
-   |         ^^^ expected type parameter `T`, found associated type
+   |      -  ^^^ expected type parameter `T`, found associated type
+   |      |
+   |      this type parameter
    |
    = note: expected associated type `<T as Foo>::Bar<'_, 'static>`
               found associated type `<<T as Baz>::Quux<'_> as Foo>::Bar<'_, 'static>`
-   = note: you might be missing a type parameter or trait bound
-   = note: required because of the requirements on the impl of `Baz` for `T`
+help: consider further restricting this bound
+   |
+LL | impl<T> Baz for T where T: Foo + Baz<Quux = T> {
+   |                                ^^^^^^^^^^^^^^^
 
 error: aborting due to previous error