We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 06fbd59 commit 8fc0d47Copy full SHA for 8fc0d47
src/librustc_lint/builtin.rs
@@ -349,7 +349,27 @@ impl MissingDoc {
349
}
350
351
352
- let has_doc = attrs.iter().any(|a| a.is_value_str() && a.check_name("doc"));
+ fn has_doc(attr: &ast::Attribute) -> bool {
353
+ if !attr.check_name("doc") {
354
+ return false;
355
+ }
356
+
357
+ if attr.is_value_str() {
358
+ return true;
359
360
361
+ if let Some(list) = attr.meta_item_list() {
362
+ for meta in list {
363
+ if meta.check_name("include") {
364
365
366
367
368
369
+ false
370
371
372
+ let has_doc = attrs.iter().any(|a| has_doc(a));
373
if !has_doc {
374
cx.span_lint(MISSING_DOCS,
375
sp,
0 commit comments