Skip to content
Closed
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
9e36fd9
stabilize `int_log`
Oct 26, 2022
8498e3a
Add examples for `pointer::mask`
WaffleLapkin Oct 28, 2022
f32e678
Rename some variables.
nnethercote Nov 3, 2022
84ca2c3
Clarify range calculations.
nnethercote Nov 3, 2022
34b32b0
Use `Mode` less.
nnethercote Nov 3, 2022
7dbf2c0
Make non-ASCII errors more consistent.
nnethercote Nov 3, 2022
a21c045
Improve comments.
nnethercote Nov 3, 2022
d963686
Refactor `cook_lexer_literal`.
nnethercote Nov 3, 2022
a203482
Inline and remove `validate_int_literal`.
nnethercote Nov 3, 2022
f8e2cef
Move intra-doc link checks to a separate function.
ehuss Nov 4, 2022
57b2290
Remove reference from the intra-doc link checker.
ehuss Nov 4, 2022
a838952
Remove `unescape_byte_literal`.
nnethercote Nov 4, 2022
43d21b5
Rename some `result` variables as `res`, for consistency.
nnethercote Nov 4, 2022
8af12eb
Add test for impl of `available_parallelism()`
flba-eb Nov 7, 2022
f67ee43
rustdoc: Add mutable to the description
yancyribbens Nov 7, 2022
d6c97a3
Simplify `unescape_{char,byte}`.
nnethercote Nov 8, 2022
f665847
const Compare Tuples
onestacked Nov 7, 2022
b6c05eb
Cleanup fn trait ref test
onestacked Nov 9, 2022
1c23d6a
Rollup merge of #103570 - lukas-code:stabilize-ilog, r=scottmcm
Dylan-DPC Nov 9, 2022
b587010
Rollup merge of #103694 - WaffleLapkin:mask_doc_example, r=scottmcm
Dylan-DPC Nov 9, 2022
1a28093
Rollup merge of #103919 - nnethercote:unescaping-cleanups, r=matklad
Dylan-DPC Nov 9, 2022
41b8f0b
Rollup merge of #103952 - ehuss:dont-intra-linkcheck-reference, r=Mar…
Dylan-DPC Nov 9, 2022
83f8d18
Rollup merge of #104095 - flba-eb:test_available_parallelism, r=thomcc
Dylan-DPC Nov 9, 2022
36d5c6c
Rollup merge of #104111 - yancyribbens:add-mutable-to-the-description…
Dylan-DPC Nov 9, 2022
f89a485
Rollup merge of #104125 - ink-feather-org:const_cmp_tuples, r=fee1-dead
Dylan-DPC Nov 9, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove reference from the intra-doc link checker.
  • Loading branch information
ehuss committed Nov 4, 2022
commit 57b229086e274c21e5544e6719271ae79a952194
34 changes: 10 additions & 24 deletions src/tools/linkchecker/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,30 +55,6 @@ const LINKCHECK_EXCEPTIONS: &[(&str, &[&str])] = &[

#[rustfmt::skip]
const INTRA_DOC_LINK_EXCEPTIONS: &[(&str, &[&str])] = &[
// This will never have links that are not in other pages.
// To avoid repeating the exceptions twice, an empty list means all broken links are allowed.
("reference/print.html", &[]),
// All the reference 'links' are actually ENBF highlighted as code
("reference/comments.html", &[
"/</code> <code>!",
"*</code> <code>!",
]),
("reference/identifiers.html", &[
"a</code>-<code>z</code> <code>A</code>-<code>Z",
"a</code>-<code>z</code> <code>A</code>-<code>Z</code> <code>0</code>-<code>9</code> <code>_",
"a</code>-<code>z</code> <code>A</code>-<code>Z</code>] [<code>a</code>-<code>z</code> <code>A</code>-<code>Z</code> <code>0</code>-<code>9</code> <code>_",
]),
("reference/tokens.html", &[
"0</code>-<code>1",
"0</code>-<code>7",
"0</code>-<code>9",
"0</code>-<code>9",
"0</code>-<code>9</code> <code>a</code>-<code>f</code> <code>A</code>-<code>F",
]),
("reference/notation.html", &[
"b</code> <code>B",
"a</code>-<code>z",
]),
// This is being used in the sense of 'inclusive range', not a markdown link
("core/ops/struct.RangeInclusive.html", &["begin</code>, <code>end"]),
("std/ops/struct.RangeInclusive.html", &["begin</code>, <code>end"]),
Expand Down Expand Up @@ -382,6 +358,16 @@ impl Checker {
source: &str,
report: &mut Report,
) {
let relative = file.strip_prefix(&self.root).expect("should always be relative to root");
// Don't check the reference. It has several legitimate things that
// look like [<code>…</code>]. The reference has its own broken link
// checker in its CI which handles this using pulldown_cmark.
//
// This checks both the end of the root (when checking just the
// reference directory) or the beginning (when checking all docs).
if self.root.ends_with("reference") || relative.starts_with("reference") {
return;
}
// Search for intra-doc links that rustdoc didn't warn about
// FIXME(#77199, 77200) Rustdoc should just warn about these directly.
// NOTE: only looks at one line at a time; in practice this should find most links
Expand Down