]> git.lizzy.rs Git - rust.git/blob - tests/ui/suggestions/suggest-blanket-impl-local-trait.stderr
Rollup merge of #106661 - mjguzik:linux_statx, r=Mark-Simulacrum
[rust.git] / tests / ui / suggestions / suggest-blanket-impl-local-trait.stderr
1 error[E0782]: trait objects must include the `dyn` keyword
2   --> $DIR/suggest-blanket-impl-local-trait.rs:13:24
3    |
4 LL | impl LocalTraitTwo for LocalTraitOne {}
5    |                        ^^^^^^^^^^^^^
6    |
7 help: add `dyn` keyword before this trait
8    |
9 LL | impl LocalTraitTwo for dyn LocalTraitOne {}
10    |                        +++
11 help: alternatively use a blanket implementation to implement `LocalTraitTwo` for all types that also implement `LocalTraitOne`
12    |
13 LL | impl<T: LocalTraitOne> LocalTraitTwo for T {}
14    |     ++++++++++++++++++                   ~
15
16 error[E0782]: trait objects must include the `dyn` keyword
17   --> $DIR/suggest-blanket-impl-local-trait.rs:18:23
18    |
19 LL | impl fmt::Display for LocalTraitOne {
20    |                       ^^^^^^^^^^^^^
21    |
22 help: add `dyn` keyword before this trait
23    |
24 LL | impl fmt::Display for dyn LocalTraitOne {
25    |                       +++
26
27 error[E0782]: trait objects must include the `dyn` keyword
28   --> $DIR/suggest-blanket-impl-local-trait.rs:26:23
29    |
30 LL | impl fmt::Display for LocalTraitTwo + Send {
31    |                       ^^^^^^^^^^^^^^^^^^^^
32    |
33 help: add `dyn` keyword before this trait
34    |
35 LL | impl fmt::Display for dyn LocalTraitTwo + Send {
36    |                       +++
37
38 error[E0782]: trait objects must include the `dyn` keyword
39   --> $DIR/suggest-blanket-impl-local-trait.rs:34:24
40    |
41 LL | impl LocalTraitOne for fmt::Display {}
42    |                        ^^^^^^^^^^^^
43    |
44 help: add `dyn` keyword before this trait
45    |
46 LL | impl LocalTraitOne for dyn fmt::Display {}
47    |                        +++
48 help: alternatively use a blanket implementation to implement `LocalTraitOne` for all types that also implement `fmt::Display`
49    |
50 LL | impl<T: fmt::Display> LocalTraitOne for T {}
51    |     +++++++++++++++++                   ~
52
53 error[E0782]: trait objects must include the `dyn` keyword
54   --> $DIR/suggest-blanket-impl-local-trait.rs:40:24
55    |
56 LL | impl LocalTraitOne for fmt::Display + Send {}
57    |                        ^^^^^^^^^^^^^^^^^^^
58    |
59 help: add `dyn` keyword before this trait
60    |
61 LL | impl LocalTraitOne for dyn fmt::Display + Send {}
62    |                        +++
63 help: alternatively use a blanket implementation to implement `LocalTraitOne` for all types that also implement `fmt::Display + Send`
64    |
65 LL | impl<T: fmt::Display + Send> LocalTraitOne for T {}
66    |     ++++++++++++++++++++++++                   ~
67
68 error[E0782]: trait objects must include the `dyn` keyword
69   --> $DIR/suggest-blanket-impl-local-trait.rs:46:29
70    |
71 LL | impl<E> GenericTrait<E> for LocalTraitOne {}
72    |                             ^^^^^^^^^^^^^
73    |
74 help: add `dyn` keyword before this trait
75    |
76 LL | impl<E> GenericTrait<E> for dyn LocalTraitOne {}
77    |                             +++
78 help: alternatively use a blanket implementation to implement `GenericTrait<E>` for all types that also implement `LocalTraitOne`
79    |
80 LL | impl<E, T: LocalTraitOne> GenericTrait<E> for T {}
81    |       ++++++++++++++++++                      ~
82
83 error[E0782]: trait objects must include the `dyn` keyword
84   --> $DIR/suggest-blanket-impl-local-trait.rs:53:35
85    |
86 LL | impl<T, E> GenericTraitTwo<E> for GenericTrait<T> {}
87    |                                   ^^^^^^^^^^^^^^^
88    |
89 help: add `dyn` keyword before this trait
90    |
91 LL | impl<T, E> GenericTraitTwo<E> for dyn GenericTrait<T> {}
92    |                                   +++
93 help: alternatively use a blanket implementation to implement `GenericTraitTwo<E>` for all types that also implement `GenericTrait<T>`
94    |
95 LL | impl<T, E, U: GenericTrait<T>> GenericTraitTwo<E> for U {}
96    |          ++++++++++++++++++++                         ~
97
98 error: aborting due to 7 previous errors
99
100 For more information about this error, try `rustc --explain E0782`.