]>
Commit | Line | Data |
---|---|---|
60c5eb7d | 1 | error[E0277]: the trait bound `std::boxed::Box<{integer}>: Foo` is not satisfied |
e74abb32 | 2 | --> $DIR/kindck-inherited-copy-bound.rs:21:16 |
b7449926 | 3 | | |
e1599b0c | 4 | LL | fn take_param<T:Foo>(foo: &T) { } |
ba9703b0 | 5 | | --- required by this bound in `take_param` |
e1599b0c | 6 | ... |
532ac7d7 | 7 | LL | take_param(&x); |
e1599b0c | 8 | | ^^ the trait `std::marker::Copy` is not implemented for `std::boxed::Box<{integer}>` |
b7449926 XL |
9 | | |
10 | = note: required because of the requirements on the impl of `Foo` for `std::boxed::Box<{integer}>` | |
b7449926 XL |
11 | |
12 | error[E0038]: the trait `Foo` cannot be made into an object | |
e74abb32 | 13 | --> $DIR/kindck-inherited-copy-bound.rs:28:19 |
b7449926 | 14 | | |
74b04a01 XL |
15 | LL | trait Foo : Copy { |
16 | | --- ---- ...because it requires `Self: Sized` | |
17 | | | | |
18 | | this trait cannot be made into an object... | |
19 | ... | |
dc9dc135 XL |
20 | LL | let z = &x as &dyn Foo; |
21 | | ^^^^^^^^ the trait `Foo` cannot be made into an object | |
b7449926 XL |
22 | |
23 | error[E0038]: the trait `Foo` cannot be made into an object | |
e74abb32 | 24 | --> $DIR/kindck-inherited-copy-bound.rs:28:13 |
b7449926 | 25 | | |
74b04a01 XL |
26 | LL | trait Foo : Copy { |
27 | | --- ---- ...because it requires `Self: Sized` | |
28 | | | | |
29 | | this trait cannot be made into an object... | |
30 | ... | |
dc9dc135 | 31 | LL | let z = &x as &dyn Foo; |
b7449926 XL |
32 | | ^^ the trait `Foo` cannot be made into an object |
33 | | | |
b7449926 | 34 | = note: required because of the requirements on the impl of `std::ops::CoerceUnsized<&dyn Foo>` for `&std::boxed::Box<{integer}>` |
e74abb32 | 35 | = note: required by cast to type `&dyn Foo` |
b7449926 XL |
36 | |
37 | error: aborting due to 3 previous errors | |
38 | ||
48663c56 | 39 | Some errors have detailed explanations: E0038, E0277. |
b7449926 | 40 | For more information about an error, try `rustc --explain E0038`. |