Skip to content

Intra-doc links #497

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 28, 2020
Merged

Intra-doc links #497

merged 1 commit into from
Dec 28, 2020

Conversation

digama0
Copy link
Contributor

@digama0 digama0 commented Nov 26, 2020

This commit changes all the documentation to use intra-doc links, which
were stabilized in rust 1.48. This helps to avoid broken links in crates
that depend on this one.

fixes #496

This commit changes all the documentation to use intra-doc links, which
were stabilized in rust 1.48. This helps to avoid broken links in crates
that depend on this one.

fixes rust-itertools#496
Copy link
Member

@phimuemue phimuemue left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not that much into documentation, but assuming that you transformed the links properly to the new format, I think this is a valuable contribution.

Comment on lines -282 to -283
/// [`multizip`]: fn.multizip.html
///
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you explain why this commit removes some lines?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In markdown if you write [foo] without defining [foo]: bar or writing [foo](bar), the link will go directly to foo. That means that if the text of the link happens to already be valid according to intra-doc link rules, there is no need to provide a custom link target (this line would end up reading [`multizip`]: multizip and rustdoc knows enough to strip the backticks).

@jswrenn jswrenn added this to the next milestone Dec 26, 2020
Copy link
Member

@jswrenn jswrenn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this! This maybe violates our MSRV policy, but not in a build-breaking way so I'm fine with merging it.

bors r+

bors bot added a commit that referenced this pull request Dec 27, 2020
497: Intra-doc links r=jswrenn a=digama0

This commit changes all the documentation to use intra-doc links, which
were stabilized in rust 1.48. This helps to avoid broken links in crates
that depend on this one.

fixes #496

Co-authored-by: Mario Carneiro <[email protected]>
@bors
Copy link
Contributor

bors bot commented Dec 27, 2020

Build failed:

@jswrenn
Copy link
Member

jswrenn commented Dec 27, 2020

Huh. I'm really not sure what to make of this build "failure". Everything appears to have passed.

@jswrenn
Copy link
Member

jswrenn commented Dec 28, 2020

bors retry

bors bot added a commit that referenced this pull request Dec 28, 2020
497: Intra-doc links r=jswrenn a=digama0

This commit changes all the documentation to use intra-doc links, which
were stabilized in rust 1.48. This helps to avoid broken links in crates
that depend on this one.

fixes #496

Co-authored-by: Mario Carneiro <[email protected]>
@bors
Copy link
Contributor

bors bot commented Dec 28, 2020

Build failed:

@jswrenn
Copy link
Member

jswrenn commented Dec 28, 2020

bors retry

@bors
Copy link
Contributor

bors bot commented Dec 28, 2020

Build succeeded:

@bors bors bot merged commit 573743a into rust-itertools:master Dec 28, 2020
@digama0 digama0 deleted the intradoc branch December 28, 2020 18:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Intra-doc links
3 participants