1 // Check that we get an error when you use `<Self as Get>::Value` in
2 // the trait definition but `Self` does not, in fact, implement `Get`.
4 // See also associated-types-no-suitable-supertrait-2.rs, which checks
5 // that we see the same error if we get around to checking the default
8 // See also run-pass/associated-types-projection-to-unrelated-trait.rs,
9 // which checks that the trait interface itself is not considered an
10 // error as long as all impls satisfy the constraint.
17 fn uhoh<U:Get>(&self, foo: U, bar: <Self as Get>::Value) {}
18 //~^ ERROR the trait bound `Self: Get` is not satisfied
21 impl<T:Get> Other for T {
22 fn uhoh<U:Get>(&self, foo: U, bar: <(T, U) as Get>::Value) {}
23 //~^ ERROR the trait bound `(T, U): Get` is not satisfied