-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Fix ICE #7012 #7021
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 ICE #7012 #7021
Conversation
r? @giraffate (rust-highfive has picked a reviewer for you, use r? to override) |
This fixes the ICE, but it looks like it might give the wrong result when #![warn(clippy::match_wildcard_for_single_variants)]
#![allow(dead_code)]
enum Color {
Red,
Green,
Blue,
Rgb(u8, u8, u8),
}
impl Color {
fn f(&self) {
match self {
Self::Red => (),
Self::Green => (),
&Self::Rgb(_, _, _) => (),
_ => (),
};
}
}
fn main() {} |
I think, instead of |
I'd like to just fix the ICE first. But feel free to file a bug and/or open a PR. |
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.
It looks good!
The test looks to fail because of formatting, so can you update on this?
Oops. Fixed. |
@bors r+ Thanks! |
📌 Commit 7014340 has been approved by |
☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test |
changelog: none
Fixes #7012