]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-43023.rs
32bd66f5a939cd08632a1b49c3d02431da6ef4e9
[rust.git] / src / test / ui / issues / issue-43023.rs
1 struct S;
2
3 impl S {
4     #[derive(Debug)] //~ ERROR `derive` may only be applied to structs, enums and unions
5     fn f() {
6         file!();
7     }
8 }
9
10 trait Tr1 {
11     #[derive(Debug)] //~ ERROR `derive` may only be applied to structs, enums and unions
12     fn f();
13 }
14
15 trait Tr2 {
16     #[derive(Debug)] //~ ERROR `derive` may only be applied to structs, enums and unions
17     type F;
18 }