fork/rust

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

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

master
2.6 KiB61 linesraw
1warning: trait objects without an explicit `dyn` are deprecated
2  --> $DIR/issue-28344.rs:4:17
3   |
4LL |     let x: u8 = BitXor::bitor(0 as u8, 0 as u8);
5   |                 ^^^^^^
6   |
7   = warning: this is accepted in the current edition (Rust 2015) 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>
9   = note: `#[warn(bare_trait_objects)]` on by default
10help: use `dyn`
11   |
12LL |     let x: u8 = <dyn BitXor>::bitor(0 as u8, 0 as u8);
13   |                 ++++       +
14
15error[E0191]: the value of the associated type `Output` (from trait `BitXor`) must be specified
16  --> $DIR/issue-28344.rs:4:17
17   |
18LL |     let x: u8 = BitXor::bitor(0 as u8, 0 as u8);
19   |                 ^^^^^^ help: specify the associated type: `BitXor<Output = Type>`
20
21error[E0599]: no function or associated item named `bitor` found for trait object `dyn BitXor<_>` in the current scope
22  --> $DIR/issue-28344.rs:4:25
23   |
24LL |     let x: u8 = BitXor::bitor(0 as u8, 0 as u8);
25   |                         ^^^^^
26   |                         |
27   |                         function or associated item not found in `dyn BitXor<_>`
28   |                         help: there is a method with a similar name: `bitxor`
29
30warning: trait objects without an explicit `dyn` are deprecated
31  --> $DIR/issue-28344.rs:10:13
32   |
33LL |     let g = BitXor::bitor;
34   |             ^^^^^^
35   |
36   = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021!
37   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
38help: use `dyn`
39   |
40LL |     let g = <dyn BitXor>::bitor;
41   |             ++++       +
42
43error[E0191]: the value of the associated type `Output` (from trait `BitXor`) must be specified
44  --> $DIR/issue-28344.rs:10:13
45   |
46LL |     let g = BitXor::bitor;
47   |             ^^^^^^ help: specify the associated type: `BitXor<Output = Type>`
48
49error[E0599]: no function or associated item named `bitor` found for trait object `dyn BitXor<_>` in the current scope
50  --> $DIR/issue-28344.rs:10:21
51   |
52LL |     let g = BitXor::bitor;
53   |                     ^^^^^
54   |                     |
55   |                     function or associated item not found in `dyn BitXor<_>`
56   |                     help: there is a method with a similar name: `bitxor`
57
58error: aborting due to 4 previous errors; 2 warnings emitted
59
60Some errors have detailed explanations: E0191, E0599.
61For more information about an error, try `rustc --explain E0191`.