summaryrefslogtreecommitdiffstats
path: root/tests/ui/associated-types/associated-types-no-suitable-supertrait.stderr
blob: 9ebc45387e86e04576cfc042dd56e90e834dc7db (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
error[E0277]: the trait bound `(T, U): Get` is not satisfied
  --> $DIR/associated-types-no-suitable-supertrait.rs:22:40
   |
LL |     fn uhoh<U:Get>(&self, foo: U, bar: <(T, U) as Get>::Value) {}
   |                                        ^^^^^^^^^^^^^^^^^^^^^^ the trait `Get` is not implemented for `(T, U)`
   |
help: this trait has no implementations, consider adding one
  --> $DIR/associated-types-no-suitable-supertrait.rs:12:1
   |
LL | trait Get {
   | ^^^^^^^^^

error[E0277]: the trait bound `Self: Get` is not satisfied
  --> $DIR/associated-types-no-suitable-supertrait.rs:17:40
   |
LL |     fn uhoh<U:Get>(&self, foo: U, bar: <Self as Get>::Value) {}
   |                                        ^^^^^^^^^^^^^^^^^^^^ the trait `Get` is not implemented for `Self`
   |
help: consider further restricting `Self`
   |
LL |     fn uhoh<U:Get>(&self, foo: U, bar: <Self as Get>::Value) where Self: Get {}
   |                                                              +++++++++++++++

error[E0277]: the trait bound `(T, U): Get` is not satisfied
  --> $DIR/associated-types-no-suitable-supertrait.rs:22:5
   |
LL |     fn uhoh<U:Get>(&self, foo: U, bar: <(T, U) as Get>::Value) {}
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Get` is not implemented for `(T, U)`
   |
help: this trait has no implementations, consider adding one
  --> $DIR/associated-types-no-suitable-supertrait.rs:12:1
   |
LL | trait Get {
   | ^^^^^^^^^

error: aborting due to 3 previous errors

For more information about this error, try `rustc --explain E0277`.