fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
3.9 KiB98 linesraw
1error: trait objects without an explicit `dyn` are deprecated
2  --> $DIR/dyn-2018-edition-lint.rs:4:17
3   |
4LL | fn function(x: &SomeTrait, y: Box<SomeTrait>) {
5   |                 ^^^^^^^^^
6   |
7   = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021!
8   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
9note: the lint level is defined here
10  --> $DIR/dyn-2018-edition-lint.rs:2:8
11   |
12LL | #[deny(bare_trait_objects)]
13   |        ^^^^^^^^^^^^^^^^^^
14help: use `dyn`
15   |
16LL | fn function(x: &dyn SomeTrait, y: Box<SomeTrait>) {
17   |                 +++
18
19error: trait objects without an explicit `dyn` are deprecated
20  --> $DIR/dyn-2018-edition-lint.rs:4:35
21   |
22LL | fn function(x: &SomeTrait, y: Box<SomeTrait>) {
23   |                                   ^^^^^^^^^
24   |
25   = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021!
26   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
27help: use `dyn`
28   |
29LL | fn function(x: &SomeTrait, y: Box<dyn SomeTrait>) {
30   |                                   +++
31
32error: trait objects without an explicit `dyn` are deprecated
33  --> $DIR/dyn-2018-edition-lint.rs:17:14
34   |
35LL |     let _x: &SomeTrait = todo!();
36   |              ^^^^^^^^^
37   |
38   = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021!
39   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
40help: use `dyn`
41   |
42LL |     let _x: &dyn SomeTrait = todo!();
43   |              +++
44
45error: trait objects without an explicit `dyn` are deprecated
46  --> $DIR/dyn-2018-edition-lint.rs:4:17
47   |
48LL | fn function(x: &SomeTrait, y: Box<SomeTrait>) {
49   |                 ^^^^^^^^^
50   |
51   = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021!
52   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
53help: use `dyn`
54   |
55LL | fn function(x: &dyn SomeTrait, y: Box<SomeTrait>) {
56   |                 +++
57
58error: trait objects without an explicit `dyn` are deprecated
59  --> $DIR/dyn-2018-edition-lint.rs:4:17
60   |
61LL | fn function(x: &SomeTrait, y: Box<SomeTrait>) {
62   |                 ^^^^^^^^^
63   |
64   = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021!
65   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
66help: use `dyn`
67   |
68LL | fn function(x: &dyn SomeTrait, y: Box<SomeTrait>) {
69   |                 +++
70
71error: trait objects without an explicit `dyn` are deprecated
72  --> $DIR/dyn-2018-edition-lint.rs:4:35
73   |
74LL | fn function(x: &SomeTrait, y: Box<SomeTrait>) {
75   |                                   ^^^^^^^^^
76   |
77   = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021!
78   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
79help: use `dyn`
80   |
81LL | fn function(x: &SomeTrait, y: Box<dyn SomeTrait>) {
82   |                                   +++
83
84error: trait objects without an explicit `dyn` are deprecated
85  --> $DIR/dyn-2018-edition-lint.rs:4:35
86   |
87LL | fn function(x: &SomeTrait, y: Box<SomeTrait>) {
88   |                                   ^^^^^^^^^
89   |
90   = warning: this is accepted in the current edition (Rust 2018) but is a hard error in Rust 2021!
91   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
92help: use `dyn`
93   |
94LL | fn function(x: &SomeTrait, y: Box<dyn SomeTrait>) {
95   |                                   +++
96
97error: aborting due to 7 previous errors
98