-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Use the replacement source instead of the original source when generating -C metadata
and -C extra-filename
#14822
base: master
Are you sure you want to change the base?
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @epage (or someone else) some time within the next two weeks. Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (
|
…ting `-C metadata` and `-C extra-filename` This commit fixes an issue when replacing two different sources with the same local one (for example using `cargo vendor`), where `rustc` errs saying that two types "defined at the same place in the same file" are "different".
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.
To help us track this, #14729 hasn't been accepted yet
(we generally ask for issues to be accepted before posting PRs, see https://doc.crates.io/contrib/process/index.html)
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.
Oops, I meant #14821, which is an issue. I updated the initial report.
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.
These two PRs are independent, one is for cargo vendor
, the other one for cargo build
. Any of them would already improve the situation and remove hacky workarounds in our workflow.
☔ The latest upstream changes (presumably bd1db93) made this pull request unmergeable. Please resolve the merge conflicts. |
☔ The latest upstream changes (possibly 081d7ba) made this pull request unmergeable. Please resolve the merge conflicts. |
What does this PR try to resolve?
This commit fixes an issue when replacing two different sources with the same local one (for example using
cargo vendor
), whererustc
errs saying that two types "defined at the same place in the same file" are "different".See #14821.
How should we test and review this PR?
Use the steps described in #14821.
Additional information
This is really useful in the context of private registries and vendored dependencies.