]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-33187.rs
Rollup merge of #91804 - woppopo:const_clone, r=oli-obk
[rust.git] / src / test / ui / issues / issue-33187.rs
1 // run-pass
2
3 struct Foo<A: Repr>(<A as Repr>::Data);
4
5 impl<A> Copy for Foo<A> where <A as Repr>::Data: Copy {}
6 impl<A> Clone for Foo<A>
7 where
8     <A as Repr>::Data: Clone,
9 {
10     fn clone(&self) -> Self {
11         Foo(self.0.clone())
12     }
13 }
14
15 trait Repr {
16     type Data;
17 }
18
19 impl<A> Repr for A {
20     type Data = u32;
21 }
22
23 fn main() {}