Clippy: main's check job passes again after #4634 (five findings in font.rs, menu.rs and panel.rs) #4679

Closed
RochDawid wants to merge 1 commit from upstream-pr/4679 into main
RochDawid commented 2026-12-01 01:36:05 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by RochDawid on 2026-12-01T01:36:05Z.


What it changes

The CI workflow's check job fails on main since the merge of #4634 (f5c3d243): its Clippy step stops on five findings in the new menu and panel code, so the job is red for every pull request based on that commit. The run on main: https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46553617760

Finding Where Change
too_many_arguments (9/7) host/font.rs:213 (text), :260 (text_right) #[allow(clippy::too_many_arguments)], as on 59 other functions in the tree
manual_is_multiple_of host/menu.rs:667 (held[i] - REPEAT_DELAY).is_multiple_of(REPEAT_EVERY) (both u32)
collapsible_if host/panel.rs:602, :668 one if … && let Some(pic) = … each

No behaviour changes: the && still evaluates std::mem::take / std::mem::replace first and renders only when it is true, as the nested if did.

How it was tested

  • GPU and profile (Series X or S, resolution, DLSS, frame generation, ray tracing): not run in a game. No behaviour changes.
  • Before: on main (f5c3d243), both Clippy gates fail with exactly the five findings above, the same as the main run linked above.
  • After (03da04b9): cargo clippy --workspace --all-targets --locked -- -D warnings and cargo clippy --workspace --all-targets --all-features --locked -- -D warnings, both for --target x86_64-pc-windows-msvc, pass. They were run on macOS through cargo xwin with Rust 1.98.1, not on Windows.
  • For shader changes, the wave sizes tested (32 and/or 64 lanes): n/a
  • cargo test passed for the crates it touches: not run. The workspace's test binaries build and link for x86_64-pc-windows-msvc (cargo xwin test --workspace --locked --no-run), but I have no Windows machine to run them on. The main run above stopped at Clippy, so its Tests step did not run either.
  • cargo xtask policy --staged: 3 files ok.

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches. Related: none found that fixes these five findings. The older Clippy pull requests (#3560, #3530, #3385, #2792, #2772, #4484) predate #4634's merge. Open pull requests that also change host/font.rs, host/menu.rs or host/panel.rs (for example #4541, #4435, #4480) do not touch these lines.
<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5577138379 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4679). Originally posted by [RochDawid](https://github.com/RochDawid) on 2026-12-01T01:36:05Z. --- ## What it changes The `CI` workflow's `check` job fails on `main` since the merge of #4634 (f5c3d243): its Clippy step stops on five findings in the new menu and panel code, so the job is red for every pull request based on that commit. The run on `main`: https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46553617760 | Finding | Where | Change | |---|---|---| | `too_many_arguments` (9/7) | `host/font.rs:213` (`text`), `:260` (`text_right`) | `#[allow(clippy::too_many_arguments)]`, as on 59 other functions in the tree | | `manual_is_multiple_of` | `host/menu.rs:667` | `(held[i] - REPEAT_DELAY).is_multiple_of(REPEAT_EVERY)` (both `u32`) | | `collapsible_if` | `host/panel.rs:602`, `:668` | one `if … && let Some(pic) = …` each | No behaviour changes: the `&&` still evaluates `std::mem::take` / `std::mem::replace` first and renders only when it is true, as the nested `if` did. ## How it was tested - GPU and profile (Series X or S, resolution, DLSS, frame generation, ray tracing): not run in a game. No behaviour changes. - Before: on `main` (f5c3d243), both Clippy gates fail with exactly the five findings above, the same as the `main` run linked above. - After (03da04b9): `cargo clippy --workspace --all-targets --locked -- -D warnings` and `cargo clippy --workspace --all-targets --all-features --locked -- -D warnings`, both for `--target x86_64-pc-windows-msvc`, pass. They were run on macOS through `cargo xwin` with Rust 1.98.1, not on Windows. - For shader changes, the wave sizes tested (32 and/or 64 lanes): n/a - `cargo test` passed for the crates it touches: not run. The workspace's test binaries build and link for `x86_64-pc-windows-msvc` (`cargo xwin test --workspace --locked --no-run`), but I have no Windows machine to run them on. The `main` run above stopped at Clippy, so its Tests step did not run either. - `cargo xtask policy --staged`: 3 files ok. ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. Related: none found that fixes these five findings. The older Clippy pull requests (#3560, #3530, #3385, #2792, #2772, #4484) predate #4634's merge. Open pull requests that also change `host/font.rs`, `host/menu.rs` or `host/panel.rs` (for example #4541, #4435, #4480) do not touch these lines.
tyr0nsur commented 2026-12-01 01:44:21 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by tyr0nsur on 2026-12-01T01:44:21Z.


Native Windows verification on 03da04b9, Rust 1.98.1, with locked dependencies:

  • cargo clippy --locked --workspace --all-targets -- -D warnings passed.
  • cargo clippy --locked --workspace --all-targets --all-features -- -D warnings passed.
  • cargo test --locked -p victory-gpu --lib -- host:: --test-threads=1 finished with 243 passed and 30 ignored.

The CI run on #4588, based on the same f5c3d243 main, hits the same five inherited findings. The workspace Clippy results above are from this PR's unchanged head. I did not run the game or visually test the overlays.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7297838649 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4679#issuecomment-7297838649). Originally posted by [tyr0nsur](https://github.com/tyr0nsur) on 2026-12-01T01:44:21Z. --- Native Windows verification on `03da04b9`, Rust 1.98.1, with locked dependencies: - `cargo clippy --locked --workspace --all-targets -- -D warnings` passed. - `cargo clippy --locked --workspace --all-targets --all-features -- -D warnings` passed. - `cargo test --locked -p victory-gpu --lib -- host:: --test-threads=1` finished with 243 passed and 30 ignored. The CI run on #4588, based on the same `f5c3d243` main, hits the same five inherited findings. The workspace Clippy results above are from this PR's unchanged head. I did not run the game or visually test the overlays.
RochDawid commented 2026-12-01 18:25:10 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by RochDawid on 2026-12-01T18:25:10Z.


Closing: main no longer has these five findings. f5c67e18 put the F1 menu back on the paged menu, and the rework up to a82703f0 rewrote font.rs, menu.rs and panel.rs, so none of the lines this changed is left. main's Clippy step still fails, but on other findings (victory-shader's emit/lower/lds_batch.rs and oracle64.rs, and new ones in victory-gpu), not on these.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7320911797 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4679#issuecomment-7320911797). Originally posted by [RochDawid](https://github.com/RochDawid) on 2026-12-01T18:25:10Z. --- Closing: `main` no longer has these five findings. f5c67e18 put the F1 menu back on the paged menu, and the rework up to a82703f0 rewrote `font.rs`, `menu.rs` and `panel.rs`, so none of the lines this changed is left. `main`'s Clippy step still fails, but on other findings (victory-shader's `emit/lower/lds_batch.rs` and `oracle64.rs`, and new ones in victory-gpu), not on these.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
trustno1-coder/VIctory-NVIDIA!4679
No description provided.