We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
missing_docs
pub extern crate
1 parent 7bb6185 commit 2884762Copy full SHA for 2884762
compiler/rustc_lint/src/builtin.rs
@@ -548,8 +548,12 @@ impl<'tcx> LateLintPass<'tcx> for MissingDoc {
548
549
fn check_item(&mut self, cx: &LateContext<'_>, it: &hir::Item<'_>) {
550
// Previously the Impl and Use types have been excluded from missing docs,
551
- // so we will continue to exclude them for compatibility
552
- if let hir::ItemKind::Impl(..) | hir::ItemKind::Use(..) = it.kind {
+ // so we will continue to exclude them for compatibility.
+ //
553
+ // The documentation on `ExternCrate` is not used at the moment so no need to warn for it.
554
+ if let hir::ItemKind::Impl(..) | hir::ItemKind::Use(..) | hir::ItemKind::ExternCrate(_) =
555
+ it.kind
556
+ {
557
return;
558
}
559
0 commit comments