]> git.lizzy.rs Git - rust.git/blob - src/test/ui/associated-types/associated-types-no-suitable-bound.rs
Merge commit '0969bc6dde001e01e7e1f58c8ccd7750f8a49ae1' into sync_cg_clif-2021-03-29
[rust.git] / src / test / ui / associated-types / associated-types-no-suitable-bound.rs
1 trait Get {
2     type Value;
3     fn get(&self) -> <Self as Get>::Value;
4 }
5
6 struct Struct {
7     x: isize,
8 }
9
10 impl Struct {
11     fn uhoh<T>(foo: <T as Get>::Value) {}
12     //~^ ERROR the trait bound `T: Get` is not satisfied
13 }
14
15 fn main() {
16 }