]> git.lizzy.rs Git - rust.git/blob - src/test/ui/generic-associated-types/issue-88360.rs
Rollup merge of #88353 - jhpratt:stabilize-array-as-ref, r=joshtriplett
[rust.git] / src / test / ui / generic-associated-types / issue-88360.rs
1 #![feature(generic_associated_types)]
2
3 trait GatTrait {
4     type Gat<'a>;
5
6     fn test(&self) -> Self::Gat<'_>;
7 }
8
9 trait SuperTrait<T>
10 where
11     for<'a> Self: GatTrait<Gat<'a> = &'a T>,
12 {
13     fn copy(&self) -> Self::Gat<'_> where T: Copy {
14         *self.test()
15         //~^ mismatched types
16     }
17 }
18
19 fn main() {}