Skip to content

Commit

Permalink
Rollup merge of rust-lang#81763 - camelid:rustdoc-passes-desc-up, r=G…
Browse files Browse the repository at this point in the history
…uillaumeGomez

Cleanup rustdoc pass descriptions a bit

Also changed a couple of comments from "intra-doc-links" to
"intra-doc links" (my understanding is that "intra-doc links" is the
standard way to refer to them).
  • Loading branch information
m-ou-se authored Feb 5, 2021
2 parents becf861 + b080d1c commit 9f6f4ac
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/librustdoc/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ crate fn create_resolver<'a>(

// Before we actually clone it, let's force all the extern'd crates to
// actually be loaded, just in case they're only referred to inside
// intra-doc-links
// intra-doc links
resolver.borrow_mut().access(|resolver| {
sess.time("load_extern_crates", || {
for extern_name in &extern_names {
Expand Down
4 changes: 2 additions & 2 deletions src/librustdoc/passes/collect_intra_doc_links.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ use super::span_of_attrs;
crate const COLLECT_INTRA_DOC_LINKS: Pass = Pass {
name: "collect-intra-doc-links",
run: collect_intra_doc_links,
description: "reads a crate's documentation to resolve intra-doc-links",
description: "resolves intra-doc links",
};

crate fn collect_intra_doc_links(krate: Crate, cx: &DocContext<'_>) -> Crate {
Expand Down Expand Up @@ -981,7 +981,7 @@ impl LinkCollector<'_, '_> {
let link_text =
disambiguator.map(|d| d.display_for(path_str)).unwrap_or_else(|| path_str.to_owned());

// In order to correctly resolve intra-doc-links we need to
// In order to correctly resolve intra-doc links we need to
// pick a base AST node to work from. If the documentation for
// this module came from an inner comment (//!) then we anchor
// our name resolution *inside* the module. If, on the other
Expand Down
4 changes: 2 additions & 2 deletions src/librustdoc/passes/doc_test_lints.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//! This pass is overloaded and runs two different lints.
//!
//! - MISSING_DOC_CODE_EXAMPLES: this lint is **UNSTABLE** and looks for public items missing doc-tests
//! - PRIVATE_DOC_TESTS: this lint is **STABLE** and looks for private items with doc-tests.
//! - MISSING_DOC_CODE_EXAMPLES: this lint is **UNSTABLE** and looks for public items missing doctests
//! - PRIVATE_DOC_TESTS: this lint is **STABLE** and looks for private items with doctests.

use super::{span_of_attrs, Pass};
use crate::clean;
Expand Down
2 changes: 1 addition & 1 deletion src/librustdoc/passes/non_autolinks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ use rustc_session::lint;
crate const CHECK_NON_AUTOLINKS: Pass = Pass {
name: "check-non-autolinks",
run: check_non_autolinks,
description: "detects URLS that could be written using angle brackets",
description: "detects URLs that could be linkified",
};

const URL_REGEX: &str = concat!(
Expand Down
2 changes: 1 addition & 1 deletion src/librustdoc/passes/strip_hidden.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ use crate::passes::{ImplStripper, Pass};
crate const STRIP_HIDDEN: Pass = Pass {
name: "strip-hidden",
run: strip_hidden,
description: "strips all doc(hidden) items from the output",
description: "strips all `#[doc(hidden)]` items from the output",
};

/// Strip items marked `#[doc(hidden)]`
Expand Down

0 comments on commit 9f6f4ac

Please sign in to comment.