summaryrefslogtreecommitdiffstats
path: root/src/test/ui/lint/unused/useless-comment.stderr
blob: 0054426fb1ec0cccf257bf1436f41f1040c8ac38 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
error: unused doc comment
  --> $DIR/useless-comment.rs:9:1
   |
LL | /// foo
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ rustdoc does not generate documentation for macro invocations
   |
note: the lint level is defined here
  --> $DIR/useless-comment.rs:3:9
   |
LL | #![deny(unused_doc_comments)]
   |         ^^^^^^^^^^^^^^^^^^^
   = help: to document an item produced by a macro, the macro must produce the documentation as part of its expansion

error: unused doc comment
  --> $DIR/useless-comment.rs:32:5
   |
LL |     /// bar
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ rustdoc does not generate documentation for macro invocations
   |
   = help: to document an item produced by a macro, the macro must produce the documentation as part of its expansion

error: unused doc comment
  --> $DIR/useless-comment.rs:13:5
   |
LL |     /// a
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
LL |     let x = 12;
   |     ----------- rustdoc does not generate documentation for statements
   |
   = help: use `//` for a plain comment

error: unused doc comment
  --> $DIR/useless-comment.rs:16:5
   |
LL | /     /// multi-line
LL | |     /// doc comment
LL | |     /// that is unused
   | |______________________^
LL | /     match x {
LL | |         /// c
LL | |         1 => {},
LL | |         _ => {}
LL | |     }
   | |_____- rustdoc does not generate documentation for expressions
   |
   = help: use `//` for a plain comment

error: unused doc comment
  --> $DIR/useless-comment.rs:20:9
   |
LL |         /// c
   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
LL |         1 => {},
   |         ------- rustdoc does not generate documentation for match arms
   |
   = help: use `//` for a plain comment

error: unused doc comment
  --> $DIR/useless-comment.rs:25:5
   |
LL |     /// foo
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
LL |     unsafe {}
   |     --------- rustdoc does not generate documentation for expressions
   |
   = help: use `//` for a plain comment

error: unused doc comment
  --> $DIR/useless-comment.rs:28:5
   |
LL |     #[doc = "foo"]
   |     ^^^^^^^^^^^^^^
LL |     #[doc = "bar"]
LL |     3;
   |     - rustdoc does not generate documentation for expressions
   |
   = help: use `//` for a plain comment

error: unused doc comment
  --> $DIR/useless-comment.rs:29:5
   |
LL |     #[doc = "bar"]
   |     ^^^^^^^^^^^^^^
LL |     3;
   |     - rustdoc does not generate documentation for expressions
   |
   = help: use `//` for a plain comment

error: unused doc comment
  --> $DIR/useless-comment.rs:35:13
   |
LL |     let x = /** comment */ 47;
   |             ^^^^^^^^^^^^^^ -- rustdoc does not generate documentation for expressions
   |
   = help: use `/* */` for a plain comment

error: unused doc comment
  --> $DIR/useless-comment.rs:37:5
   |
LL |       /// dox
   |       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
LL | /     {
LL | |
LL | |     }
   | |_____- rustdoc does not generate documentation for expressions
   |
   = help: use `//` for a plain comment

error: aborting due to 10 previous errors