We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0a66f03 commit 782b917Copy full SHA for 782b917
gcc/testsuite/rust/compile/issue-3144.rs
@@ -0,0 +1,29 @@
1
+#[lang = "sized"]
2
+pub trait Sized {}
3
+
4
+#[lang = "copy"]
5
+trait Copy {}
6
7
+#[lang = "clone"]
8
+pub trait Clone {
9
+ fn clone(&self) -> Self;
10
+}
11
12
+impl Clone for i32 {
13
+ fn clone(&self) -> i32 {
14
+ *self
15
+ }
16
17
18
+struct S {}
19
20
+#[derive(Clone, Copy)]
21
+// { dg-error {bounds not satisfied for S .Clone. is not satisfied .E0277.} "" { target *-*-* } .-1 }
22
+struct S2 {
23
+ a: i32,
24
+ s: S,
25
26
27
+fn main() -> i32 {
28
+ 0
29
0 commit comments