-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Correctly handle remapping from path containing the current directory with trailing paths #85344
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
Conversation
(rust-highfive has picked a reviewer for you, use r? to override) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the PR, @cbeuw!
I left some comments below for making the test case more robust. Otherwise this is good to merge.
@michaelwoerister All addressed. Thanks for reviewing! |
@bors r+ |
📌 Commit 08c55bd has been approved by |
⌛ Testing commit 08c55bd with merge a6e1d5007597713f57bba6f231b4fce0d9ce39fb... |
This comment has been minimized.
This comment has been minimized.
💔 Test failed - checks-actions |
@bors r+ |
📌 Commit 7ed9f2e has been approved by |
☀️ Test successful - checks-actions |
If we have a
auxiliary/lib.rs
, and we generate the metadata with--remap-path-prefix $PWD/auxiliary=xyz
, the path to$PWD/auxiliary/lib.rs
won't be correctly remapped in the metadata. This is because internally, path to the working directory itself and relative paths to files under the working directory are remapped separately (hence neither are affected since neither has$PWD/auxiliary
as prefix), but the concatenation between the working directory and the relative path is not remapped. This PR fixes that.