Clippy: main is clean again with -D warnings, with and without --all-features (3 lints) #840

Open
MamaLeVrai wants to merge 2 commits from upstream-pr/841 into main
MamaLeVrai commented 2026-11-25 10:12:21 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by MamaLeVrai on 2026-11-25T10:12:21Z.


On main (0b0074e), cargo clippy --workspace --all-targets --locked -- -D warnings fails in victory-gpu on this machine (Windows 11, RX 6950 XT, Rust 1.98.1), with and without --all-features. Four lints (three of them were already there when I opened this; shadow.rs got the fourth since), none changing behaviour:

  • placed_filler_twins (resource.rs) is read only by the diagnostics memory report (copystat.rs, which is built with the diagnostics feature only), so it was dead code without that feature: it is compiled with the feature now (#[cfg(all(windows, feature = "diagnostics"))]).
  • Rig::depth_written (indirect.rs) is kept next to depth_tested but never read: renamed _depth_written, as the struct's other kept fields (_kept, _target_heaps) are.
  • The scissor census in draw.rs sorts with sort_unstable_by_key(|r| Reverse(r.1)) instead of sort_unstable_by(|a, b| b.1.cmp(&a.1)).
  • shadow.rs (the own-view write census): n % 16384 == 0 is n.is_multiple_of(16384).

Checks: cargo clippy --workspace --all-targets --locked -- -D warnings and the same with --all-features: clean. cargo test --workspace --locked: the crates before victory-gpu pass; in victory-gpu the library's tests pass apart from the intermittent failures that main has (the budget test, see #849; the crash of the test binary, see #850). The title was not run.

AI-assisted (Claude Code); no game data.

🤖 Generated with Claude Code

<!-- greyfinch-sync:fxceless/victory-fork:issue:6602110166 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/841). Originally posted by [MamaLeVrai](https://github.com/MamaLeVrai) on 2026-11-25T10:12:21Z. --- On `main` (`0b0074e`), `cargo clippy --workspace --all-targets --locked -- -D warnings` fails in `victory-gpu` on this machine (Windows 11, RX 6950 XT, Rust 1.98.1), with and without `--all-features`. Four lints (three of them were already there when I opened this; `shadow.rs` got the fourth since), none changing behaviour: - `placed_filler_twins` (`resource.rs`) is read only by the diagnostics memory report (`copystat.rs`, which is built with the `diagnostics` feature only), so it was dead code without that feature: it is compiled with the feature now (`#[cfg(all(windows, feature = "diagnostics"))]`). - `Rig::depth_written` (`indirect.rs`) is kept next to `depth_tested` but never read: renamed `_depth_written`, as the struct's other kept fields (`_kept`, `_target_heaps`) are. - The scissor census in `draw.rs` sorts with `sort_unstable_by_key(|r| Reverse(r.1))` instead of `sort_unstable_by(|a, b| b.1.cmp(&a.1))`. - `shadow.rs` (the own-view write census): `n % 16384 == 0` is `n.is_multiple_of(16384)`. **Checks:** `cargo clippy --workspace --all-targets --locked -- -D warnings` and the same with `--all-features`: clean. `cargo test --workspace --locked`: the crates before `victory-gpu` pass; in `victory-gpu` the library's tests pass apart from the intermittent failures that `main` has (the budget test, see #849; the crash of the test binary, see #850). The title was not run. AI-assisted (Claude Code); no game data. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
copilot-pull-request-reviewer[bot commented 2026-11-25 11:10:22 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by copilot-pull-request-reviewer[bot] on 2026-11-25T10:12:35Z.

Review: COMMENTED


Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

<!-- greyfinch-sync:fxceless/victory-fork:review:6055617311 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/841#pullrequestreview-6055617311). Originally posted by [copilot-pull-request-reviewer[bot]](https://github.com/copilot-pull-request-reviewer%5Bbot%5D) on 2026-11-25T10:12:35Z. **Review:** COMMENTED --- Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/841:upstream-pr/841'
git switch 'upstream-pr/841'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/841'
git switch 'upstream-pr/841'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/841'
git switch 'upstream-pr/841'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/841'
git switch 'main'
git merge --squash 'upstream-pr/841'
git switch 'main'
git merge --ff-only 'upstream-pr/841'
git switch 'main'
git merge 'upstream-pr/841'
git push origin 'main'
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
fxceless/victory-fork!840
No description provided.