]> git.lizzy.rs Git - rust.git/blob - tests/ui/lint/lint-attr-everywhere-late.stderr
Auto merge of #106884 - clubby789:fieldless-enum-debug, r=michaelwoerister
[rust.git] / tests / ui / lint / lint-attr-everywhere-late.stderr
1 error: missing documentation for a type alias
2   --> $DIR/lint-attr-everywhere-late.rs:35:1
3    |
4 LL | pub type MissingDocType = i32;
5    | ^^^^^^^^^^^^^^^^^^^^^^^
6    |
7 note: the lint level is defined here
8   --> $DIR/lint-attr-everywhere-late.rs:34:8
9    |
10 LL | #[deny(missing_docs)]
11    |        ^^^^^^^^^^^^
12
13 error: missing documentation for a struct
14   --> $DIR/lint-attr-everywhere-late.rs:43:1
15    |
16 LL | pub struct ItemOuter;
17    | ^^^^^^^^^^^^^^^^^^^^
18    |
19 note: the lint level is defined here
20   --> $DIR/lint-attr-everywhere-late.rs:42:8
21    |
22 LL | #[deny(missing_docs)]
23    |        ^^^^^^^^^^^^
24
25 error: missing documentation for a module
26   --> $DIR/lint-attr-everywhere-late.rs:45:1
27    |
28 LL | pub mod module_inner {
29    | ^^^^^^^^^^^^^^^^^^^^
30    |
31 note: the lint level is defined here
32   --> $DIR/lint-attr-everywhere-late.rs:46:13
33    |
34 LL |     #![deny(missing_docs)]
35    |             ^^^^^^^^^^^^
36
37 error: missing documentation for a function
38   --> $DIR/lint-attr-everywhere-late.rs:47:5
39    |
40 LL |     pub fn missing_inner() {}
41    |     ^^^^^^^^^^^^^^^^^^^^^^
42
43 error: missing documentation for an associated function
44   --> $DIR/lint-attr-everywhere-late.rs:54:5
45    |
46 LL |     pub fn inherent_denied_from_inner() {}
47    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
48    |
49 note: the lint level is defined here
50   --> $DIR/lint-attr-everywhere-late.rs:52:13
51    |
52 LL |     #![deny(missing_docs)]
53    |             ^^^^^^^^^^^^
54
55 error: missing documentation for an associated function
56   --> $DIR/lint-attr-everywhere-late.rs:59:5
57    |
58 LL |     pub fn inherent_fn() {}
59    |     ^^^^^^^^^^^^^^^^^^^^
60    |
61 note: the lint level is defined here
62   --> $DIR/lint-attr-everywhere-late.rs:58:12
63    |
64 LL |     #[deny(missing_docs)]
65    |            ^^^^^^^^^^^^
66
67 error: missing documentation for an associated constant
68   --> $DIR/lint-attr-everywhere-late.rs:62:5
69    |
70 LL |     pub const INHERENT_CONST: i32 = 1;
71    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
72    |
73 note: the lint level is defined here
74   --> $DIR/lint-attr-everywhere-late.rs:61:12
75    |
76 LL |     #[deny(missing_docs)]
77    |            ^^^^^^^^^^^^
78
79 error: missing documentation for a trait
80   --> $DIR/lint-attr-everywhere-late.rs:65:1
81    |
82 LL | pub trait TraitInner {
83    | ^^^^^^^^^^^^^^^^^^^^
84    |
85 note: the lint level is defined here
86   --> $DIR/lint-attr-everywhere-late.rs:66:13
87    |
88 LL |     #![deny(missing_docs)]
89    |             ^^^^^^^^^^^^
90
91 error: missing documentation for a trait
92   --> $DIR/lint-attr-everywhere-late.rs:69:1
93    |
94 LL | pub trait AssociatedTraitInner {
95    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
96    |
97 note: the lint level is defined here
98   --> $DIR/lint-attr-everywhere-late.rs:70:13
99    |
100 LL |     #![deny(missing_docs)]
101    |             ^^^^^^^^^^^^
102
103 error: missing documentation for an associated function
104   --> $DIR/lint-attr-everywhere-late.rs:72:5
105    |
106 LL |     fn denied_from_inner() {}
107    |     ^^^^^^^^^^^^^^^^^^^^^^
108
109 error: missing documentation for an associated function
110   --> $DIR/lint-attr-everywhere-late.rs:79:5
111    |
112 LL |     fn assoc_fn() {}
113    |     ^^^^^^^^^^^^^
114    |
115 note: the lint level is defined here
116   --> $DIR/lint-attr-everywhere-late.rs:78:12
117    |
118 LL |     #[deny(missing_docs)]
119    |            ^^^^^^^^^^^^
120
121 error: missing documentation for an associated constant
122   --> $DIR/lint-attr-everywhere-late.rs:82:5
123    |
124 LL |     const ASSOC_CONST: u8 = 1;
125    |     ^^^^^^^^^^^^^^^^^^^^^
126    |
127 note: the lint level is defined here
128   --> $DIR/lint-attr-everywhere-late.rs:81:12
129    |
130 LL |     #[deny(missing_docs)]
131    |            ^^^^^^^^^^^^
132
133 error: missing documentation for an associated type
134   --> $DIR/lint-attr-everywhere-late.rs:85:5
135    |
136 LL |     type AssocType;
137    |     ^^^^^^^^^^^^^^
138    |
139 note: the lint level is defined here
140   --> $DIR/lint-attr-everywhere-late.rs:84:12
141    |
142 LL |     #[deny(missing_docs)]
143    |            ^^^^^^^^^^^^
144
145 error: missing documentation for a variant
146   --> $DIR/lint-attr-everywhere-late.rs:112:5
147    |
148 LL |     Variant1,
149    |     ^^^^^^^^
150    |
151 note: the lint level is defined here
152   --> $DIR/lint-attr-everywhere-late.rs:111:12
153    |
154 LL |     #[deny(missing_docs)]
155    |            ^^^^^^^^^^^^
156
157 error: `clashing1` redeclared with a different signature
158   --> $DIR/lint-attr-everywhere-late.rs:123:5
159    |
160 LL |         fn clashing1();
161    |         --------------- `clashing1` previously declared here
162 ...
163 LL |     fn clashing1(_: i32);
164    |     ^^^^^^^^^^^^^^^^^^^^^ this signature doesn't match the previous declaration
165    |
166    = note: expected `unsafe extern "C" fn()`
167               found `unsafe extern "C" fn(i32)`
168 note: the lint level is defined here
169   --> $DIR/lint-attr-everywhere-late.rs:122:13
170    |
171 LL |     #![deny(clashing_extern_declarations)]
172    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
173
174 error: `clashing2` redeclared with a different signature
175   --> $DIR/lint-attr-everywhere-late.rs:128:5
176    |
177 LL |         fn clashing2();
178    |         --------------- `clashing2` previously declared here
179 ...
180 LL |     fn clashing2(_: i32);
181    |     ^^^^^^^^^^^^^^^^^^^^^ this signature doesn't match the previous declaration
182    |
183    = note: expected `unsafe extern "C" fn()`
184               found `unsafe extern "C" fn(i32)`
185 note: the lint level is defined here
186   --> $DIR/lint-attr-everywhere-late.rs:127:12
187    |
188 LL |     #[deny(clashing_extern_declarations)]
189    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
190
191 error: types that do not implement `Drop` can still have drop glue, consider instead using `std::mem::needs_drop` to detect whether a type is trivially dropped
192   --> $DIR/lint-attr-everywhere-late.rs:93:38
193    |
194 LL |     fn denied_from_inner(_x: Box<dyn Drop>) {}
195    |                                      ^^^^
196    |
197 note: the lint level is defined here
198   --> $DIR/lint-attr-everywhere-late.rs:91:13
199    |
200 LL |     #![deny(dyn_drop)]
201    |             ^^^^^^^^
202
203 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
204   --> $DIR/lint-attr-everywhere-late.rs:96:21
205    |
206 LL |     fn assoc_fn() { discriminant::<i32>(&123); }
207    |                     ^^^^^^^^^^^^^^^^^^^^^^^^^
208    |
209 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
210   --> $DIR/lint-attr-everywhere-late.rs:96:41
211    |
212 LL |     fn assoc_fn() { discriminant::<i32>(&123); }
213    |                                         ^^^^
214 note: the lint level is defined here
215   --> $DIR/lint-attr-everywhere-late.rs:95:12
216    |
217 LL |     #[deny(enum_intrinsics_non_enums)]
218    |            ^^^^^^^^^^^^^^^^^^^^^^^^^
219
220 error: literal out of range for `u8`
221   --> $DIR/lint-attr-everywhere-late.rs:98:59
222    |
223 LL |     #[deny(overflowing_literals)] const ASSOC_CONST: u8 = 1000;
224    |                                                           ^^^^
225    |
226    = note: the literal `1000` does not fit into the type `u8` whose range is `0..=255`
227 note: the lint level is defined here
228   --> $DIR/lint-attr-everywhere-late.rs:98:12
229    |
230 LL |     #[deny(overflowing_literals)] const ASSOC_CONST: u8 = 1000;
231    |            ^^^^^^^^^^^^^^^^^^^^
232
233 error: variable `PARAM` should have a snake case name
234   --> $DIR/lint-attr-everywhere-late.rs:131:37
235    |
236 LL | fn function(#[deny(non_snake_case)] PARAM: i32) {}
237    |                                     ^^^^^ help: convert the identifier to snake case: `param`
238    |
239 note: the lint level is defined here
240   --> $DIR/lint-attr-everywhere-late.rs:131:20
241    |
242 LL | fn function(#[deny(non_snake_case)] PARAM: i32) {}
243    |                    ^^^^^^^^^^^^^^
244
245 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
246   --> $DIR/lint-attr-everywhere-late.rs:139:13
247    |
248 LL |     let _ = discriminant::<i32>(&123);
249    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
250    |
251 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
252   --> $DIR/lint-attr-everywhere-late.rs:139:33
253    |
254 LL |     let _ = discriminant::<i32>(&123);
255    |                                 ^^^^
256 note: the lint level is defined here
257   --> $DIR/lint-attr-everywhere-late.rs:138:12
258    |
259 LL |     #[deny(enum_intrinsics_non_enums)]
260    |            ^^^^^^^^^^^^^^^^^^^^^^^^^
261
262 error: variable `PARAM` should have a snake case name
263   --> $DIR/lint-attr-everywhere-late.rs:145:44
264    |
265 LL |     let closure = |#[deny(non_snake_case)] PARAM: i32| {};
266    |                                            ^^^^^ help: convert the identifier to snake case: `param`
267    |
268 note: the lint level is defined here
269   --> $DIR/lint-attr-everywhere-late.rs:145:27
270    |
271 LL |     let closure = |#[deny(non_snake_case)] PARAM: i32| {};
272    |                           ^^^^^^^^^^^^^^
273
274 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
275   --> $DIR/lint-attr-everywhere-late.rs:155:13
276    |
277 LL |             discriminant::<i32>(&123);
278    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
279    |
280 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
281   --> $DIR/lint-attr-everywhere-late.rs:155:33
282    |
283 LL |             discriminant::<i32>(&123);
284    |                                 ^^^^
285 note: the lint level is defined here
286   --> $DIR/lint-attr-everywhere-late.rs:153:17
287    |
288 LL |         #![deny(enum_intrinsics_non_enums)]
289    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
290
291 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
292   --> $DIR/lint-attr-everywhere-late.rs:161:13
293    |
294 LL |             discriminant::<i32>(&123);
295    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
296    |
297 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
298   --> $DIR/lint-attr-everywhere-late.rs:161:33
299    |
300 LL |             discriminant::<i32>(&123);
301    |                                 ^^^^
302 note: the lint level is defined here
303   --> $DIR/lint-attr-everywhere-late.rs:159:16
304    |
305 LL |         #[deny(enum_intrinsics_non_enums)]
306    |                ^^^^^^^^^^^^^^^^^^^^^^^^^
307
308 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
309   --> $DIR/lint-attr-everywhere-late.rs:168:9
310    |
311 LL |         discriminant::<i32>(&123);
312    |         ^^^^^^^^^^^^^^^^^^^^^^^^^
313    |
314 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
315   --> $DIR/lint-attr-everywhere-late.rs:168:29
316    |
317 LL |         discriminant::<i32>(&123);
318    |                             ^^^^
319 note: the lint level is defined here
320   --> $DIR/lint-attr-everywhere-late.rs:167:17
321    |
322 LL |         #![deny(enum_intrinsics_non_enums)]
323    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
324
325 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
326   --> $DIR/lint-attr-everywhere-late.rs:172:9
327    |
328 LL |         discriminant::<i32>(&123);
329    |         ^^^^^^^^^^^^^^^^^^^^^^^^^
330    |
331 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
332   --> $DIR/lint-attr-everywhere-late.rs:172:29
333    |
334 LL |         discriminant::<i32>(&123);
335    |                             ^^^^
336 note: the lint level is defined here
337   --> $DIR/lint-attr-everywhere-late.rs:171:16
338    |
339 LL |         #[deny(enum_intrinsics_non_enums)]
340    |                ^^^^^^^^^^^^^^^^^^^^^^^^^
341
342 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
343   --> $DIR/lint-attr-everywhere-late.rs:177:5
344    |
345 LL |     discriminant::<i32>(&123);
346    |     ^^^^^^^^^^^^^^^^^^^^^^^^^
347    |
348 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
349   --> $DIR/lint-attr-everywhere-late.rs:177:25
350    |
351 LL |     discriminant::<i32>(&123);
352    |                         ^^^^
353 note: the lint level is defined here
354   --> $DIR/lint-attr-everywhere-late.rs:176:12
355    |
356 LL |     #[deny(enum_intrinsics_non_enums)]
357    |            ^^^^^^^^^^^^^^^^^^^^^^^^^
358
359 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
360   --> $DIR/lint-attr-everywhere-late.rs:179:41
361    |
362 LL |     [#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123)];
363    |                                         ^^^^^^^^^^^^^^^^^^^^^^^^^
364    |
365 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
366   --> $DIR/lint-attr-everywhere-late.rs:179:61
367    |
368 LL |     [#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123)];
369    |                                                             ^^^^
370 note: the lint level is defined here
371   --> $DIR/lint-attr-everywhere-late.rs:179:13
372    |
373 LL |     [#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123)];
374    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
375
376 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
377   --> $DIR/lint-attr-everywhere-late.rs:180:41
378    |
379 LL |     (#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123),);
380    |                                         ^^^^^^^^^^^^^^^^^^^^^^^^^
381    |
382 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
383   --> $DIR/lint-attr-everywhere-late.rs:180:61
384    |
385 LL |     (#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123),);
386    |                                                             ^^^^
387 note: the lint level is defined here
388   --> $DIR/lint-attr-everywhere-late.rs:180:13
389    |
390 LL |     (#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123),);
391    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
392
393 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
394   --> $DIR/lint-attr-everywhere-late.rs:182:45
395    |
396 LL |     call(#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123));
397    |                                             ^^^^^^^^^^^^^^^^^^^^^^^^^
398    |
399 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
400   --> $DIR/lint-attr-everywhere-late.rs:182:65
401    |
402 LL |     call(#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123));
403    |                                                                 ^^^^
404 note: the lint level is defined here
405   --> $DIR/lint-attr-everywhere-late.rs:182:17
406    |
407 LL |     call(#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123));
408    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^
409
410 error: the return value of `mem::discriminant` is unspecified when called with a non-enum type
411   --> $DIR/lint-attr-everywhere-late.rs:184:52
412    |
413 LL |     TupleStruct(#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123));
414    |                                                    ^^^^^^^^^^^^^^^^^^^^^^^^^
415    |
416 note: the argument to `discriminant` should be a reference to an enum, but it was passed a reference to a `i32`, which is not an enum.
417   --> $DIR/lint-attr-everywhere-late.rs:184:72
418    |
419 LL |     TupleStruct(#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123));
420    |                                                                        ^^^^
421 note: the lint level is defined here
422   --> $DIR/lint-attr-everywhere-late.rs:184:24
423    |
424 LL |     TupleStruct(#[deny(enum_intrinsics_non_enums)] discriminant::<i32>(&123));
425    |                        ^^^^^^^^^^^^^^^^^^^^^^^^^
426
427 error: aborting due to 31 previous errors
428