]> git.lizzy.rs Git - rust.git/blob - tests/ui/generic-associated-types/issue-88459.rs
Rollup merge of #103702 - WaffleLapkin:lift-sized-bounds-from-pointer-methods-where...
[rust.git] / tests / ui / generic-associated-types / issue-88459.rs
1 // check-pass
2
3 trait Trait {
4     type Assoc<'a>;
5 }
6
7 fn f<T: Trait>(_: T, _: impl Fn(T::Assoc<'_>)) {}
8
9 struct Type;
10
11 impl Trait for Type {
12     type Assoc<'a> = ();
13 }
14
15 fn main() {
16     f(Type, |_|());
17 }