Skip to content
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

Fix duplicate bounds for const_trait_impl #88851

Merged
merged 1 commit into from
Sep 14, 2021

Conversation

fee1-dead
Copy link
Member

Fixes #88383.

Compare the constness of the candidates before winnowing and removing a ~const BoundCandidate.

@rust-highfive
Copy link
Collaborator

r? @wesleywiser

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Sep 11, 2021
@fee1-dead
Copy link
Member Author

r? @oli-obk

@rust-highfive rust-highfive assigned oli-obk and unassigned wesleywiser Sep 13, 2021
@oli-obk
Copy link
Contributor

oli-obk commented Sep 13, 2021

Would it make sense to drop the NotConst bound if the constness is unequal? It does not add anything new after all

@fee1-dead
Copy link
Member Author

It is actually being done, there is an else if block underneath that does what you have described.

@oli-obk
Copy link
Contributor

oli-obk commented Sep 13, 2021

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Sep 13, 2021

📌 Commit a0b83f5 has been approved by oli-obk

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Sep 13, 2021
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Sep 13, 2021
Fix duplicate bounds for const_trait_impl

Fixes rust-lang#88383.

Compare the constness of the candidates before winnowing and removing a `~const` `BoundCandidate`.
This was referenced Sep 13, 2021
workingjubilee added a commit to workingjubilee/rustc that referenced this pull request Sep 14, 2021
Fix duplicate bounds for const_trait_impl

Fixes rust-lang#88383.

Compare the constness of the candidates before winnowing and removing a `~const` `BoundCandidate`.
workingjubilee added a commit to workingjubilee/rustc that referenced this pull request Sep 14, 2021
Fix duplicate bounds for const_trait_impl

Fixes rust-lang#88383.

Compare the constness of the candidates before winnowing and removing a `~const` `BoundCandidate`.
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 14, 2021
…laumeGomez

Rollup of 7 pull requests

Successful merges:

 - rust-lang#88033 (Add links for primitives in "jump to definition" feature)
 - rust-lang#88722 (Make `UnsafeCell::get_mut` const)
 - rust-lang#88851 (Fix duplicate bounds for const_trait_impl)
 - rust-lang#88859 (interpreter PointerArithmetic: use new Size helper methods)
 - rust-lang#88885 (Fix jump def background)
 - rust-lang#88894 (Improve error message for missing trait in trait impl)
 - rust-lang#88896 (Reduce possibility of flaky tests)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit a9bc2ef into rust-lang:master Sep 14, 2021
@rustbot rustbot added this to the 1.57.0 milestone Sep 14, 2021
@fee1-dead fee1-dead deleted the dup-bound branch September 16, 2021 04:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicate bounds behave differently depending on their order for const_trait_impl
6 participants