Skip to content
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

rustdoc: Fix redirect pages for renamed reexports #34245

Merged
merged 1 commit into from
Jun 15, 2016

Conversation

ollie27
Copy link
Member

@ollie27 ollie27 commented Jun 12, 2016

We need to use the name of the target not the name of the current item
when creating the link.

An example in std is std::sys::ext.

@rust-highfive
Copy link
Collaborator

r? @steveklabnik

(rust_highfive has picked a reviewer for you, use r? to override)

@GuillaumeGomez
Copy link
Member

👍

if let ItemType::Module = ty {
write!(url, "{}/index.html", target_name).unwrap();
} else {
write!(url, "{}.{}.html", ty.to_static_str(), target_name).unwrap();
Copy link
Member

Choose a reason for hiding this comment

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

This seems duplicated with item_path, perhaps the two could be refactored to share code?

Copy link
Member Author

Choose a reason for hiding this comment

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

Done.

We need to use the name of the target not the name of the current item
when creating the link.
@alexcrichton
Copy link
Member

@bors: r+ 0c742d2

@bors
Copy link
Contributor

bors commented Jun 14, 2016

⌛ Testing commit 0c742d2 with merge f46ed6f...

@bors
Copy link
Contributor

bors commented Jun 14, 2016

💔 Test failed - auto-win-gnu-32-opt-rustbuild

@alexcrichton
Copy link
Member

@bors: retry

  • mingw is weird

On Tue, Jun 14, 2016 at 8:58 PM, bors notifications@github.com wrote:

💔 Test failed - auto-win-gnu-32-opt-rustbuild
http://buildbot.rust-lang.org/builders/auto-win-gnu-32-opt-rustbuild/builds/1450


You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#34245 (comment), or mute
the thread
https://github.com/notifications/unsubscribe/AAD95Ea9zD7dCJpQ31LNR-3pMskmhWkaks5qLvnagaJpZM4Iz5Uc
.

@bors
Copy link
Contributor

bors commented Jun 15, 2016

⌛ Testing commit 0c742d2 with merge 1a942f6...

bors added a commit that referenced this pull request Jun 15, 2016
rustdoc: Fix redirect pages for renamed reexports

We need to use the name of the target not the name of the current item
when creating the link.

An example in `std` is [`std::sys::ext`](https://doc.rust-lang.org/nightly/std/sys/ext/index.html).
@bors bors merged commit 0c742d2 into rust-lang:master Jun 15, 2016
@ollie27 ollie27 deleted the rustdoc_redirect_rename branch June 15, 2016 23:03
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.

6 participants