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

[single_match, single_match_else] fix suggestion when match irrefutable #13324

Merged
merged 2 commits into from
Sep 8, 2024

Conversation

WeiTheShinobi
Copy link
Contributor

@WeiTheShinobi WeiTheShinobi commented Aug 30, 2024

fixes #13012

changelog:[single_match, single_match_else]: fix suggestion when match irrefutable

@rustbot
Copy link
Collaborator

rustbot commented Aug 30, 2024

r? @dswij

rustbot has assigned @dswij.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Aug 30, 2024
@WeiTheShinobi WeiTheShinobi force-pushed the single_match branch 2 times, most recently from de07605 to 77c92fa Compare August 30, 2024 21:22
Comment on lines 307 to 309
{ println!() }

{ println!() }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we suggest this into an expr instead of a block?

For L313, I guess it might change the behaviour if we move out of the block, but this part is fine.

@dswij
Copy link
Member

dswij commented Sep 8, 2024

Thank you! @bors r+

@bors
Copy link
Collaborator

bors commented Sep 8, 2024

📌 Commit e3ca249 has been approved by dswij

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented Sep 8, 2024

⌛ Testing commit e3ca249 with merge bcf528b...

@bors
Copy link
Collaborator

bors commented Sep 8, 2024

☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test
Approved by: dswij
Pushing bcf528b to master...

1 similar comment
@bors
Copy link
Collaborator

bors commented Sep 8, 2024

☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test
Approved by: dswij
Pushing bcf528b to master...

@bors bors merged commit bcf528b into rust-lang:master Sep 8, 2024
8 checks passed
@bors
Copy link
Collaborator

bors commented Sep 8, 2024

👀 Test was successful, but fast-forwarding failed: 422 Changes must be made through a pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties
Projects
None yet
Development

Successfully merging this pull request may close these issues.

single_match suggestion causes deny-by-default eq-op warning
4 participants