]> git.proxmox.com Git - rustc.git/blobdiff - src/test/ui/hrtb/hrtb-higher-ranker-supertraits.stderr
New upstream version 1.50.0+dfsg1
[rustc.git] / src / test / ui / hrtb / hrtb-higher-ranker-supertraits.stderr
index 768bc6c71847f445934d9cb820cd33a73445acd0..0123faa36dbcd8fdbcdd1c072dd9cc99a398a889 100644 (file)
@@ -1,30 +1,34 @@
 error[E0277]: the trait bound `for<'tcx> F: Foo<'tcx>` is not satisfied
   --> $DIR/hrtb-higher-ranker-supertraits.rs:18:26
    |
-LL |     where F : Foo<'x>
-   |                      - help: consider further restricting type parameter `F`: `, F: for<'tcx> Foo<'tcx>`
-...
 LL |     want_foo_for_any_tcx(f);
    |                          ^ the trait `for<'tcx> Foo<'tcx>` is not implemented for `F`
 ...
 LL | fn want_foo_for_any_tcx<F>(f: &F)
-   |    --------------------
+   |    -------------------- required by a bound in this
 LL |     where F : for<'tcx> Foo<'tcx>
    |               ------------------- required by this bound in `want_foo_for_any_tcx`
+   |
+help: consider further restricting this bound
+   |
+LL |     where F : Foo<'x> + for<'tcx> Foo<'tcx>
+   |                       ^^^^^^^^^^^^^^^^^^^^^
 
 error[E0277]: the trait bound `for<'ccx> B: Bar<'ccx>` is not satisfied
   --> $DIR/hrtb-higher-ranker-supertraits.rs:35:26
    |
-LL |     where B : Bar<'x>
-   |                      - help: consider further restricting type parameter `B`: `, B: for<'ccx> Bar<'ccx>`
-...
 LL |     want_bar_for_any_ccx(b);
    |                          ^ the trait `for<'ccx> Bar<'ccx>` is not implemented for `B`
 ...
 LL | fn want_bar_for_any_ccx<B>(b: &B)
-   |    --------------------
+   |    -------------------- required by a bound in this
 LL |     where B : for<'ccx> Bar<'ccx>
    |               ------------------- required by this bound in `want_bar_for_any_ccx`
+   |
+help: consider further restricting this bound
+   |
+LL |     where B : Bar<'x> + for<'ccx> Bar<'ccx>
+   |                       ^^^^^^^^^^^^^^^^^^^^^
 
 error: aborting due to 2 previous errors