]> git.proxmox.com Git - rustc.git/blobdiff - src/test/ui/traits/inheritance/repeated-supertrait-ambig.stderr
New upstream version 1.55.0+dfsg1
[rustc.git] / src / test / ui / traits / inheritance / repeated-supertrait-ambig.stderr
index bb11f18e54505bd8f953ae9599edbb2a8f405847..bc7b863ca4f5175392ef1a0451c994a5575e7e0e 100644 (file)
@@ -18,21 +18,26 @@ LL | fn with_trait<C:CompareToInts + CompareTo<i32>>(c: &C) -> bool {
 error[E0277]: the trait bound `dyn CompareToInts: CompareTo<i32>` is not satisfied
   --> $DIR/repeated-supertrait-ambig.rs:34:5
    |
-LL |     fn same_as(&self, t: T) -> bool;
-   |     -------------------------------- required by `CompareTo::same_as`
-...
 LL |     <dyn CompareToInts>::same_as(c, 22)
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `CompareTo<i32>` is not implemented for `dyn CompareToInts`
+   |
+note: required by `CompareTo::same_as`
+  --> $DIR/repeated-supertrait-ambig.rs:9:5
+   |
+LL |     fn same_as(&self, t: T) -> bool;
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error[E0277]: the trait bound `C: CompareTo<i32>` is not satisfied
   --> $DIR/repeated-supertrait-ambig.rs:38:5
    |
-LL |     fn same_as(&self, t: T) -> bool;
-   |     -------------------------------- required by `CompareTo::same_as`
-...
 LL |     CompareTo::same_as(c, 22)
    |     ^^^^^^^^^^^^^^^^^^ the trait `CompareTo<i32>` is not implemented for `C`
    |
+note: required by `CompareTo::same_as`
+  --> $DIR/repeated-supertrait-ambig.rs:9:5
+   |
+LL |     fn same_as(&self, t: T) -> bool;
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 help: consider further restricting this bound
    |
 LL | fn with_ufcs2<C:CompareToInts + CompareTo<i32>>(c: &C) -> bool {