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