-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Disable non_exhaustive_omitted_patterns within matches! macro #144331
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
Disable non_exhaustive_omitted_patterns within matches! macro #144331
Conversation
Oh, I should probably add a test that enables the lint, uses |
This comment has been minimized.
This comment has been minimized.
You need |
Could you add a regression test at r? @Nadrieril since you expressed some preference to how this is implemented on #117304 This seems like objectively correct behavior but it is still a user-facing adjustment to lints and builtin macros, so we'll also ask somebody from lang to take a look once CI passes. |
|
Yup, I noticed. I guess (I'm guessing because that unstable feature is enabled by core, so uses of the macro within core are fine) |
This looks good. I also don't think this is relevant to lang, it's an adjustment to a nightly feature, no? |
You're right, missed that this nightly features were required to get this flagged in the first place. |
9454aa2
to
ab6a52a
Compare
This comment has been minimized.
This comment has been minimized.
I've added a test and made sure it failed (to compile |
ab6a52a
to
0e30629
Compare
This comment has been minimized.
This comment has been minimized.
@bors r+ |
So, after CI failed initially I updated the test expectations of the failing |
Yeah I looked at the diff output it's fine. I think such scopes are added if needed for lints which is what's happening here. Did you try something like |
Rollup of 10 pull requests Successful merges: - #144331 (Disable non_exhaustive_omitted_patterns within matches! macro) - #144376 (Suggest unwrapping when private method name is available in inner type) - #144421 (Call `is_parsed_attribute` rather than keeping track of a list of parsed attributes manually) - #144424 (Allow setting `release-blog-post` label with rustbot) - #144427 (rename ext_tool_checks to extra_checks and use mod.rs) - #144435 (rustc-dev-guide subtree update) - #144448 (Limit defaultness query to impl of trait) - #144462 (Allow pretty printing paths with `-Zself-profile-events=args`) - #144463 (change_tracker: fix a typo) - #144468 (resolve: Do not create `NameResolutions` on access unless necessary) r? `@ghost` `@rustbot` modify labels: rollup
Nah, I had no clue what to even try and it wasn't that hard to do by hand. I am used to the error message telling me what to do 😅 |
Rollup merge of #144331 - jplatte:matches-allow-non_exhaustive_omitted_patterns, r=Nadrieril Disable non_exhaustive_omitted_patterns within matches! macro Closes #117304. I believe I can skip all of the bootstrap stuff mentioned in #117304 (comment) due to https://blog.rust-lang.org/inside-rust/2025/05/29/redesigning-the-initial-bootstrap-sequence/, right? cc `@Jules-Bertholet`
Rollup of 10 pull requests Successful merges: - rust-lang/rust#144331 (Disable non_exhaustive_omitted_patterns within matches! macro) - rust-lang/rust#144376 (Suggest unwrapping when private method name is available in inner type) - rust-lang/rust#144421 (Call `is_parsed_attribute` rather than keeping track of a list of parsed attributes manually) - rust-lang/rust#144424 (Allow setting `release-blog-post` label with rustbot) - rust-lang/rust#144427 (rename ext_tool_checks to extra_checks and use mod.rs) - rust-lang/rust#144435 (rustc-dev-guide subtree update) - rust-lang/rust#144448 (Limit defaultness query to impl of trait) - rust-lang/rust#144462 (Allow pretty printing paths with `-Zself-profile-events=args`) - rust-lang/rust#144463 (change_tracker: fix a typo) - rust-lang/rust#144468 (resolve: Do not create `NameResolutions` on access unless necessary) r? `@ghost` `@rustbot` modify labels: rollup
…ve_omitted_patterns, r=Nadrieril Disable non_exhaustive_omitted_patterns within matches! macro Closes rust-lang#117304. I believe I can skip all of the bootstrap stuff mentioned in rust-lang#117304 (comment) due to https://blog.rust-lang.org/inside-rust/2025/05/29/redesigning-the-initial-bootstrap-sequence/, right? cc `@Jules-Bertholet`
Closes #117304.
I believe I can skip all of the bootstrap stuff mentioned in #117304 (comment) due to https://blog.rust-lang.org/inside-rust/2025/05/29/redesigning-the-initial-bootstrap-sequence/, right?
cc @Jules-Bertholet