arch: Fix Clippy lints for CPUID updates - #202
Merged
Merged
Conversation
This fixes lints of the following kind:
```
error: this `if` can be collapsed into the outer `match`
--> arch/src/x86_64/mod.rs:874:17
|
874 | / if !config.amx {
875 | | if entry.index == 0 {
876 | | entry.edx &= !((1 << AMX_BF16) | (1 << AMX_TILE) | (1 << AMX_INT8));
... |
882 | | }
| |_________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
= note: `-D clippy::collapsible-match` implied by `-D clippy::all`
= help: to override `-D clippy::all` add `#[allow(clippy::collapsible_match)]`
help: collapse nested if block
|
873 ~ 0x7
874 ~ if !config.amx => {
875 | if entry.index == 0 {
...
881 | }
882 ~ }
|
```
On-behalf-of: SAP pascal.scholz@sap.com
Signed-off-by: Pascal Scholz <pascal.scholz@cyberus-technology.de>
Member
clippy frequently changes, probably different versions in use |
phip1611
approved these changes
Sep 3, 2026
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.
Weird that that the CI didn't catch it some days ago. I found this when executing Clippy locally on my machine.
This fixes lints of the following kind: