Skip to content

Conversation

b-naber
Copy link
Contributor

@b-naber b-naber commented May 24, 2022

Previously we included the outermost type that caused a structural match violation in the error message and stated that that type must be annotated with #[derive(Eq, PartialEq)] even if it already had that annotation. This PR outputs the correct type in the error message.

Fixes #97278

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label May 24, 2022
@rust-highfive
Copy link
Contributor

r? @michaelwoerister

(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 May 24, 2022
@michaelwoerister
Copy link
Member

Looks like an improvement. Thanks for the PR, @b-naber!

@bors r+

@bors
Copy link
Collaborator

bors commented May 25, 2022

📌 Commit 86e8bbe has been approved by michaelwoerister

@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 May 25, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request May 25, 2022
Rollup of 5 pull requests

Successful merges:

 - rust-lang#97302 (Do writeback of Closure params before visiting the parent expression)
 - rust-lang#97328 (rustc: Fix ICE in native library error reporting)
 - rust-lang#97351 (Output correct type responsible for structural match violation)
 - rust-lang#97398 (Add regression test for rust-lang#82830)
 - rust-lang#97400 (Fix a typo on Struct `Substructure`)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 8a3ad49 into rust-lang:master May 25, 2022
@rustbot rustbot added this to the 1.63.0 milestone May 25, 2022
@bors
Copy link
Collaborator

bors commented May 25, 2022

⌛ Testing commit 86e8bbe with merge 1b5e121...

@b-naber b-naber deleted the adt-const-params-structural-match-violation branch May 29, 2022 18:15
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. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[feature(adt_const_params)] Bar doesn't derive both PartialEq and Eq
5 participants