]> git.lizzy.rs Git - rust.git/blob - src/test/ui/derives/derive-on-trait-item-or-impl-item.stderr
Auto merge of #106025 - matthiaskrgr:rollup-vz5rqah, r=matthiaskrgr
[rust.git] / src / test / ui / derives / derive-on-trait-item-or-impl-item.stderr
1 error[E0774]: `derive` may only be applied to `struct`s, `enum`s and `union`s
2   --> $DIR/derive-on-trait-item-or-impl-item.rs:2:5
3    |
4 LL |     #[derive(Clone)]
5    |     ^^^^^^^^^^^^^^^^ not applicable here
6 LL |
7 LL |     type Bar;
8    |     --------- not a `struct`, `enum` or `union`
9
10 error[E0774]: `derive` may only be applied to `struct`s, `enum`s and `union`s
11   --> $DIR/derive-on-trait-item-or-impl-item.rs:10:5
12    |
13 LL |     #[derive(Clone)]
14    |     ^^^^^^^^^^^^^^^^ not applicable here
15 LL |
16 LL |     fn bar(&self) {}
17    |     ---------------- not a `struct`, `enum` or `union`
18
19 error: aborting due to 2 previous errors
20
21 For more information about this error, try `rustc --explain E0774`.