Use relative paths for std links in rustc-docs#152243
Use relative paths for std links in rustc-docs#152243rust-bors[bot] merged 1 commit intorust-lang:mainfrom
Conversation
Signed-off-by: arferreira <arfs.antonio@gmail.com>
|
Thanks for the work! One thought I had: how do we test that? ^^' |
Yeahh def! I tested manually, just built the compiler docs and comparing the HTML output before and after :) |
|
I expect as much. :p That was an open question for other rust contributors: how do we check that automatically in the CI to ensure it doesn't regress? Maybe you have an idea @Kobzol ? |
|
What's the exact thing that you want to check? That all links in the docs are relative? Doesn't rustdoc already has some similar tests in one of its test suites? |
|
Nah, just a few cross-crate ones. And we do, but it's unrelated here: we need this fix because std/core are handled differently and point to each others with |
|
I guess it would either have to be some rustdoc test that scans the HTML (using some existing machinery), or it would require some large-ish changes. Because the docs that we dist are in the dist components, and we don't really have a notion of testing these today, outside of one hardcoded sanity checks for the PGO-ed rustc toolchain. |
|
Nothing we can check then? Oh well, I guess I can live with that. @bors r+ rollup |
…=GuillaumeGomez Use relative paths for std links in rustc-docs Fixes rust-lang#151496 This adds `--extern-html-root-url` for each `STD_PUBLIC_CRATES` entry pointing to `../`, so that `rustc-docs` links to the locally installed `rust-docs` via relative paths. r? @GuillaumeGomez @rami3l
…=GuillaumeGomez Use relative paths for std links in rustc-docs Fixes rust-lang#151496 This adds `--extern-html-root-url` for each `STD_PUBLIC_CRATES` entry pointing to `../`, so that `rustc-docs` links to the locally installed `rust-docs` via relative paths. r? @GuillaumeGomez @rami3l
…=GuillaumeGomez Use relative paths for std links in rustc-docs Fixes rust-lang#151496 This adds `--extern-html-root-url` for each `STD_PUBLIC_CRATES` entry pointing to `../`, so that `rustc-docs` links to the locally installed `rust-docs` via relative paths. r? @GuillaumeGomez @rami3l
…uwer Rollup of 5 pull requests Successful merges: - #149960 (add `unreachable_cfg_select_predicates` lint) - #152126 (Convert to inline diagnostics in `rustc_mir_build`) - #152186 (Convert to inline diagnostics in `rustc_const_eval`) - #152234 (Dont strip const blocks in array lengths) - #152243 (Use relative paths for std links in rustc-docs)
Rollup merge of #152243 - arferreira:fix-rustc-docs-local, r=GuillaumeGomez Use relative paths for std links in rustc-docs Fixes #151496 This adds `--extern-html-root-url` for each `STD_PUBLIC_CRATES` entry pointing to `../`, so that `rustc-docs` links to the locally installed `rust-docs` via relative paths. r? @GuillaumeGomez @rami3l
Fixes #151496
This adds
--extern-html-root-urlfor eachSTD_PUBLIC_CRATESentry pointing to../, so thatrustc-docslinks to the locally installedrust-docsvia relative paths.r? @GuillaumeGomez @rami3l