]> git.proxmox.com Git - rustc.git/blame - src/test/ui/cast/cast-to-unsized-trait-object-suggestion.stderr
New upstream version 1.46.0~beta.2+dfsg1
[rustc.git] / src / test / ui / cast / cast-to-unsized-trait-object-suggestion.stderr
CommitLineData
8faf50e0 1error[E0620]: cast to unsized type: `&{integer}` as `dyn std::marker::Send`
0731742a 2 --> $DIR/cast-to-unsized-trait-object-suggestion.rs:2:5
041b39d2 3 |
dc9dc135
XL
4LL | &1 as dyn Send;
5 | ^^^^^^--------
041b39d2 6 | |
dc9dc135 7 | help: try casting to a reference instead: `&dyn Send`
041b39d2 8
8faf50e0 9error[E0620]: cast to unsized type: `std::boxed::Box<{integer}>` as `dyn std::marker::Send`
0731742a 10 --> $DIR/cast-to-unsized-trait-object-suggestion.rs:3:5
041b39d2 11 |
dc9dc135
XL
12LL | Box::new(1) as dyn Send;
13 | ^^^^^^^^^^^^^^^--------
041b39d2 14 | |
f035d41b 15 | help: you can cast to a `Box` instead: `Box<dyn Send>`
041b39d2
XL
16
17error: aborting due to 2 previous errors
18
0531ce1d 19For more information about this error, try `rustc --explain E0620`.