-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of #108129 - GuillaumeGomez:correctly-handle-links-start…
…ing-with-whitespace, r=petrochenkov Correctly handle links starting with whitespace Part of #107995. I just got this issue, wrote a fix and then saw the issue. So here's the PR. ^^' r? `@petrochenkov`
- Loading branch information
Showing
3 changed files
with
32 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// Regression test for <https://github.com/rust-lang/rust/issues/107995>. | ||
|
||
#![crate_name = "foo"] | ||
|
||
// @has 'foo/fn.foo.html' | ||
// @has - '//*[@class="docblock"]//a[@href="fn.bar.html"]' 'bar`' | ||
/// A foo, see also [ bar`] | ||
pub fn foo() {} | ||
|
||
// @has 'foo/fn.bar.html' | ||
// @has - '//*[@class="docblock"]' 'line Path line' | ||
// @has - '//*[@class="docblock"]//a[@href="struct.Path.html"]' 'Path' | ||
#[doc = "line ["] | ||
#[doc = "Path"] | ||
#[doc = "] line"] | ||
pub fn bar() {} | ||
|
||
// @has 'foo/fn.another.html' | ||
// @has - '//*[@class="docblock"]//a[@href="struct.Path.html"]' 'Path' | ||
/// [ `Path`] | ||
pub fn another() {} | ||
|
||
// @has 'foo/fn.last.html' | ||
// @has - '//*[@class="docblock"]//a[@href="struct.Path.html"]' 'Path' | ||
/// [ Path`] | ||
pub fn last() {} | ||
|
||
pub struct Path; |