Uh oh!
There was an error while loading. Please reload this page.
rustdoc: Fix source-links for files with absolute-paths - #31835
Conversation
53bd2ee to
78ca2e2CompareThere was a problem hiding this comment.
Perhaps this could be a unix-only rustdoc test which has a module with the path as /dev/null? That would avoid run-make and you could still check for the module page, right?
There was a problem hiding this comment.
Didn't think of that, but it seems like rustdoc doesn't generate files for empty public modules.
That did make another bug clear though, namely that absolute paths not contained in the root directory are still broken just like before.
(I'm gonna try to put these in a src/__root__ directory; for example /dev/null -> src/__root__/dev/null.html)
There was a problem hiding this comment.
Hm ok, I just try to avoid run-make like the plague as makefiles are basically impossible to get right on both windows and unix...
alexcrichton
commented
Feb 23, 2016
@bors: r+ 78ca2e256ed86906f5d295a129f3d51e124dbbeb |
mitaa
commented
Feb 23, 2016
I pushed an update so that this also works for absolute paths not contained in the root directory. That would unfortunately be even worse to test, so I didn't include one. (works locally though) |
There was a problem hiding this comment.
This seems kinda sketchy, perhaps the iterator below could use components on Path to only look at the Component::Normal parts?
mitaa
commented
Feb 23, 2016
(updated) I've preserved the |
alexcrichton
commented
Feb 23, 2016
@bors: r+ 4037a7da77e529a421c4fe32e910f26abacae1af |
bors
commented
Feb 24, 2016
⌛ Testing commit 4037a7d with merge 4159981... |
bors
commented
Feb 24, 2016
💔 Test failed - auto-win-gnu-32-nopt-t |
`clean_srcpath` tries to make the source-path relative to `src_root`, but this didn't work since `src_root` itself wasn't absolute.
mitaa
commented
Feb 24, 2016
I think I've made your This has required commit mitaa@27ca250, because |
fixes#26995
r? @alexcrichton