Enable clippy::manual_let_else workspace-wide and fix issues - #4430
Merged
Kenny Kerr (kennykerr) merged 2 commits intoMay 18, 2026
Merged
Conversation
Agent-Logs-Url: https://github.com/microsoft/windows-rs/sessions/43bf84a8-c955-44d8-9ef3-5ab80bb0ef5f Co-authored-by: kennykerr <9845234+kennykerr@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
Kenny Kerr (kennykerr)
May 18, 2026 19:01
View session
Contributor
There was a problem hiding this comment.
Pull request overview
Enables the clippy::manual_let_else lint workspace-wide and rewrites the existing match patterns it flags into let ... else form across libraries and tests.
Changes:
- Add
manual_let_else = "warn"to[workspace.lints.clippy]. - Convert single-arm
matchreturning/panicking on the other arm intolet ... elsein several library sites. - Apply the same rewrite in test fixtures.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| Cargo.toml | Enable manual_let_else lint workspace-wide |
| crates/libs/interface/src/guid.rs | Rewrite missing-part check as let Some(part) = ... else |
| crates/libs/rdl/src/clang/callback.rs | Rewrite function_pointee match as let Some(...) else |
| crates/libs/rdl/src/clang/const.rs | Rewrite parse_body match as let Some(value) = ... else |
| crates/libs/rdl/src/reader/attribute_ref.rs | Two rewrites: ctor_values check and enum variant value check |
| crates/tests/libs/bindgen/tests/fixtures.rs | Rewrite Result match as let Err(payload) = ... else |
| crates/tests/libs/rdl/tests/guid-derive.rs | Three rewrites for Value::U32/U16 extractions |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Collaborator
|
Copilot resolve the merge conflicts in this pull request |
Kenny Kerr (kennykerr)
marked this pull request as ready for review
May 18, 2026 19:18
…al-let-else-workspace-wide # Conflicts: # Cargo.toml Co-authored-by: kennykerr <9845234+kennykerr@users.noreply.github.com>
Contributor
Author
Kenny Kerr (kennykerr)
deleted the
copilot/enable-manual-let-else-workspace-wide
branch
May 18, 2026 19:26
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.