Skip to content

Commit f767f54

Browse files
rename NO_CRATE_LEVEL_DOC lint into MISSING_CRATE_LEVEL_DOC
1 parent 12607ef commit f767f54

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

src/librustc_session/lint/builtin.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -387,7 +387,7 @@ declare_lint! {
387387
}
388388

389389
declare_lint! {
390-
pub NO_CRATE_LEVEL_DOC,
390+
pub MISSING_CRATE_LEVEL_DOC,
391391
Allow,
392392
"detects crates with no crate-level documentation"
393393
}
@@ -553,7 +553,7 @@ declare_lint_pass! {
553553
UNSTABLE_NAME_COLLISIONS,
554554
IRREFUTABLE_LET_PATTERNS,
555555
INTRA_DOC_LINK_RESOLUTION_FAILURE,
556-
NO_CRATE_LEVEL_DOC,
556+
MISSING_CRATE_LEVEL_DOC,
557557
MISSING_DOC_CODE_EXAMPLES,
558558
PRIVATE_DOC_TESTS,
559559
WHERE_CLAUSES_OBJECT_SAFETY,

src/librustdoc/core.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
249249
let missing_docs = rustc_lint::builtin::MISSING_DOCS.name;
250250
let missing_doc_example = rustc_lint::builtin::MISSING_DOC_CODE_EXAMPLES.name;
251251
let private_doc_tests = rustc_lint::builtin::PRIVATE_DOC_TESTS.name;
252-
let no_crate_level_doc = rustc_lint::builtin::NO_CRATE_LEVEL_DOC.name;
252+
let no_crate_level_doc = rustc_lint::builtin::MISSING_CRATE_LEVEL_DOC.name;
253253

254254
// In addition to those specific lints, we also need to whitelist those given through
255255
// command line, otherwise they'll get ignored and we don't want that.
@@ -417,7 +417,7 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
417417
match m.doc_value() {
418418
None | Some("") => {
419419
let mut diag = tcx.struct_lint_node(
420-
rustc_lint::builtin::NO_CRATE_LEVEL_DOC,
420+
rustc_lint::builtin::MISSING_CRATE_LEVEL_DOC,
421421
ctxt.as_local_hir_id(m.def_id).unwrap(),
422422
"No documentation found on this crate top module.\n\n\
423423
Maybe you could be interested into looking at this documentation:\n\
@@ -432,8 +432,7 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
432432

433433
fn report_deprecated_attr(name: &str, diag: &rustc_errors::Handler) {
434434
let mut msg = diag.struct_warn(&format!(
435-
"the `#![doc({})]` attribute is \
436-
considered deprecated",
435+
"the `#![doc({})]` attribute is considered deprecated",
437436
name
438437
));
439438
msg.warn(

0 commit comments

Comments
 (0)