Commit 7c5ea06
authored
Rollup merge of #150172 - Urgau:rustdoc-remap-fixes, r=GuillaumeGomez
Handle remapped paths correctly when generating "Source" links
Fixes rust-lang/rust#150100.
This PR fixes a regression introduced by [#149709](rust-lang/rust#149709), I was overzealous in my changes (https://github.com/rust-lang/rust/pull/149709/changes#diff-e1cf7ef2fb411d24980cd4cbea1e867cc36029e9496e1ceca64cfb6a0e3510f6) and accidentally changed the behavior of `rustdoc` in the presence of remapped, to simply reject them instead of handling them.
With this PR remapped paths are handled correctly, in a similar way as it was before.
~~I added a run-make test to make sure we don't regress it again, a simple `rustdoc` test in not sufficient as `rustdoc` is not called on the auxiliary crate. It's not pretty but it works.~~ rust-lang/rust#150172 (comment)
rustdoc doesn't have any handling for `--remap-path-scope`, so I used the `MACRO` scope (it was already used [elsewhere](https://github.com/rust-lang/rust/blob/b889870082dd0b0e3594bbfbebb4545d54710829/src/librustdoc/clean/types.rs#L154).
cf. https://rust-lang.zulipchat.com/#narrow/channel/266220-t-rustdoc/topic/source.20links.20missing.20for.20nightly.20std.20docsFile tree
0 file changed
+0
-0
lines changed0 file changed
+0
-0
lines changed
0 commit comments