fork/rust

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

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

master
3.3 KiB117 linesraw
1error: expected expression, found keyword `else`
2  --> $DIR/unused-doc-comments-edge-cases.rs:17:5
3   |
4LL |     else {
5   |     ^^^^ expected expression
6
7error[E0658]: attributes on expressions are experimental
8  --> $DIR/unused-doc-comments-edge-cases.rs:23:5
9   |
10LL |     /// useless doc comment
11   |     ^^^^^^^^^^^^^^^^^^^^^^^
12   |
13   = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
14   = help: add `#![feature(stmt_expr_attributes)]` to the crate attributes to enable
15   = help: `///` is for documentation comments. For a plain comment, use `//`.
16
17error: unused doc comment
18  --> $DIR/unused-doc-comments-edge-cases.rs:6:9
19   |
20LL |         /// useless doc comment
21   |         ^^^^^^^^^^^^^^^^^^^^^^^
22LL |
23LL |         _ => false,
24   |         ---------- rustdoc does not generate documentation for match arms
25   |
26   = help: use `//` for a plain comment
27note: the lint level is defined here
28  --> $DIR/unused-doc-comments-edge-cases.rs:1:9
29   |
30LL | #![deny(unused_doc_comments)]
31   |         ^^^^^^^^^^^^^^^^^^^
32
33error: unused doc comment
34  --> $DIR/unused-doc-comments-edge-cases.rs:23:5
35   |
36LL |     /// useless doc comment
37   |     ^^^^^^^^^^^^^^^^^^^^^^^
38...
39LL |     num == 3
40   |     --- rustdoc does not generate documentation for expressions
41   |
42   = help: use `//` for a plain comment
43
44error: unused doc comment
45  --> $DIR/unused-doc-comments-edge-cases.rs:33:9
46   |
47LL |         /// useless doc comment
48   |         ^^^^^^^^^^^^^^^^^^^^^^^
49LL |
50LL |         foo: 3
51   |         ------ rustdoc does not generate documentation for expression fields
52   |
53   = help: use `//` for a plain comment
54
55error: unused doc comment
56  --> $DIR/unused-doc-comments-edge-cases.rs:45:9
57   |
58LL |         /// useless doc comment
59   |         ^^^^^^^^^^^^^^^^^^^^^^^
60LL |
61LL |         foo
62   |         --- rustdoc does not generate documentation for pattern fields
63   |
64   = help: use `//` for a plain comment
65
66error: unused doc comment
67  --> $DIR/unused-doc-comments-edge-cases.rs:55:27
68   |
69LL | fn doc_comment_on_generic<#[doc = "x"] T>(val: T) {}
70   |                           ^^^^^^^^^^^^ - rustdoc does not generate documentation for generic parameters
71   |
72   = help: use `//` for a plain comment
73
74error: unused doc comment
75  --> $DIR/unused-doc-comments-edge-cases.rs:59:5
76   |
77LL |       /// unused doc comment
78   |       ^^^^^^^^^^^^^^^^^^^^^^
79LL |
80LL | /     {
81LL | |         let x = 12;
82LL | |     }
83   | |_____- rustdoc does not generate documentation for expressions
84   |
85   = help: use `//` for a plain comment
86
87error: unused doc comment
88  --> $DIR/unused-doc-comments-edge-cases.rs:66:1
89   |
90LL |   /// unused doc comment
91   |   ^^^^^^^^^^^^^^^^^^^^^^
92LL |
93LL | / extern "C" {
94LL | |     fn foo();
95LL | | }
96   | |_- rustdoc does not generate documentation for extern blocks
97   |
98   = help: use `//` for a plain comment
99
100error[E0308]: mismatched types
101  --> $DIR/unused-doc-comments-edge-cases.rs:14:9
102   |
103LL | /     if num == 3 {
104LL | |         true
105   | |         ^^^^ expected `()`, found `bool`
106LL | |     }
107   | |_____- expected this to be `()`
108   |
109help: you might have meant to return this value
110   |
111LL |         return true;
112   |         ++++++     +
113
114error: aborting due to 10 previous errors
115
116Some errors have detailed explanations: E0308, E0658.
117For more information about an error, try `rustc --explain E0308`.