@@ -2,10 +2,8 @@ error[E0277]: the trait bound `C: Copy` is not satisfied
22 --> $DIR/deriving-copyclone.rs:31:13
33 |
44LL | is_copy(B { a: 1, b: C });
5- | ------- ^^^^^^^^^^^^^^^^
6- | | |
7- | | expected an implementor of trait `Copy`
8- | | help: consider borrowing here: `&B { a: 1, b: C }`
5+ | ------- ^^^^^^^^^^^^^^^^ expected an implementor of trait `Copy`
6+ | |
97 | required by a bound introduced by this call
108 |
119note: required because of the requirements on the impl of `Copy` for `B<C>`
@@ -19,15 +17,17 @@ note: required by a bound in `is_copy`
1917LL | fn is_copy<T: Copy>(_: T) {}
2018 | ^^^^ required by this bound in `is_copy`
2119 = note: this error originates in the derive macro `Copy` (in Nightly builds, run with -Z macro-backtrace for more info)
20+ help: consider borrowing here
21+ |
22+ LL | is_copy(&B { a: 1, b: C });
23+ | +
2224
2325error[E0277]: the trait bound `C: Clone` is not satisfied
2426 --> $DIR/deriving-copyclone.rs:32:14
2527 |
2628LL | is_clone(B { a: 1, b: C });
27- | -------- ^^^^^^^^^^^^^^^^
28- | | |
29- | | expected an implementor of trait `Clone`
30- | | help: consider borrowing here: `&B { a: 1, b: C }`
29+ | -------- ^^^^^^^^^^^^^^^^ expected an implementor of trait `Clone`
30+ | |
3131 | required by a bound introduced by this call
3232 |
3333note: required because of the requirements on the impl of `Clone` for `B<C>`
@@ -41,15 +41,17 @@ note: required by a bound in `is_clone`
4141LL | fn is_clone<T: Clone>(_: T) {}
4242 | ^^^^^ required by this bound in `is_clone`
4343 = note: this error originates in the derive macro `Clone` (in Nightly builds, run with -Z macro-backtrace for more info)
44+ help: consider borrowing here
45+ |
46+ LL | is_clone(&B { a: 1, b: C });
47+ | +
4448
4549error[E0277]: the trait bound `D: Copy` is not satisfied
4650 --> $DIR/deriving-copyclone.rs:35:13
4751 |
4852LL | is_copy(B { a: 1, b: D });
49- | ------- ^^^^^^^^^^^^^^^^
50- | | |
51- | | expected an implementor of trait `Copy`
52- | | help: consider borrowing here: `&B { a: 1, b: D }`
53+ | ------- ^^^^^^^^^^^^^^^^ expected an implementor of trait `Copy`
54+ | |
5355 | required by a bound introduced by this call
5456 |
5557note: required because of the requirements on the impl of `Copy` for `B<D>`
@@ -63,6 +65,10 @@ note: required by a bound in `is_copy`
6365LL | fn is_copy<T: Copy>(_: T) {}
6466 | ^^^^ required by this bound in `is_copy`
6567 = note: this error originates in the derive macro `Copy` (in Nightly builds, run with -Z macro-backtrace for more info)
68+ help: consider borrowing here
69+ |
70+ LL | is_copy(&B { a: 1, b: D });
71+ | +
6672
6773error: aborting due to 3 previous errors
6874
0 commit comments