Make clippy pass on the #439 integration branch #442

Closed
Kal0s-design wants to merge 3 commits from upstream-pr/442 into review/local-integration-20261129
Kal0s-design commented 2026-11-29 12:47:56 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by Kal0s-design on 2026-11-29T12:47:56Z.


Targets #439's branch (review/local-integration-20261129), where the Clippy job fails. With this PR, the CI commands pass locally on Windows:

  • cargo clippy --workspace --all-targets --locked -- -D warnings: clean
  • the same with --all-features: clean
  • cargo check --workspace --profile diag --all-features --locked: clean
  • cargo test -p victory-gpu -p victory-hle -p victory-loader --lib: 555 / 228 / 72 passed. cargo test -p victory-shader --lib emit: 229 passed.
  • cargo xtask policy: ok. git diff --check: clean.

Two commits:

  1. d2ddf68: the two real lints. manual_is_multiple_of in emit/water_tile_slots.rs and let_and_return in an emit/mod.rs test helper.
  2. d9d4aaf: a SAFETY comment right before every block undocumented_unsafe_blocks flagged. #439 moves that lint from allow to warn, and CI's -D warnings makes each one an error: 89 without features, 131 with --all-features.
    • Most already had a comment clippy doesn't see. It was a "SAFETY (all)" / "(both)" note covering several blocks, a comment above a macro or a let with the unsafe further in, or a comment separated from its block by other statements. Those now repeat the author's own reason next to each block, or move next to it.
    • In timeline/hooks.rs the calls sit in macro input, where clippy only sees a comment inside the closure, so those closures become blocks. The test helper closure in indirect.rs gets the same treatment.
    • About a dozen had no comment. Those got a reason read from the surrounding code: compose.rs, indirect.rs's barrier pass, the FidelityFX host queries and destroy, the DualSense preparsed-data free and the panel's ntdll lookup.

Nothing else changes in the code. Worth a read where a reason is mine and not the original author's. Those are the blocks listed in the last point above.

AI-assisted: yes

🤖 Generated with Claude Code

<!-- greyfinch-sync:TaynanGT/Vice-Tay:issue:5550853102 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/442). Originally posted by [Kal0s-design](https://github.com/Kal0s-design) on 2026-11-29T12:47:56Z. --- Targets #439's branch (`review/local-integration-20261129`), where the Clippy job fails. With this PR, the CI commands pass locally on Windows: - `cargo clippy --workspace --all-targets --locked -- -D warnings`: clean - the same with `--all-features`: clean - `cargo check --workspace --profile diag --all-features --locked`: clean - `cargo test -p victory-gpu -p victory-hle -p victory-loader --lib`: 555 / 228 / 72 passed. `cargo test -p victory-shader --lib emit`: 229 passed. - `cargo xtask policy`: ok. `git diff --check`: clean. Two commits: 1. **d2ddf68:** the two real lints. `manual_is_multiple_of` in `emit/water_tile_slots.rs` and `let_and_return` in an `emit/mod.rs` test helper. 2. **d9d4aaf:** a SAFETY comment right before every block `undocumented_unsafe_blocks` flagged. #439 moves that lint from `allow` to `warn`, and CI's `-D warnings` makes each one an error: 89 without features, 131 with `--all-features`. - Most already had a comment clippy doesn't see. It was a "SAFETY (all)" / "(both)" note covering several blocks, a comment above a macro or a `let` with the `unsafe` further in, or a comment separated from its block by other statements. Those now repeat the author's own reason next to each block, or move next to it. - In `timeline/hooks.rs` the calls sit in macro input, where clippy only sees a comment inside the closure, so those closures become blocks. The test helper closure in `indirect.rs` gets the same treatment. - About a dozen had no comment. Those got a reason read from the surrounding code: `compose.rs`, `indirect.rs`'s barrier pass, the FidelityFX host queries and destroy, the DualSense preparsed-data free and the panel's ntdll lookup. Nothing else changes in the code. Worth a read where a reason is mine and not the original author's. Those are the blocks listed in the last point above. AI-assisted: yes 🤖 Generated with [Claude Code](https://claude.com/claude-code)
TaynanGT commented 2026-11-29 13:23:26 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by TaynanGT on 2026-11-29T13:23:26Z.


Thanks for addressing both real lints and the unsafe-block documentation. I integrated the changes locally, retaining the existing mapped-image safety check where the branches differed. Full Clippy validation on the consolidated tree is still pending.

<!-- greyfinch-sync:TaynanGT/Vice-Tay:comment:7256501979 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/442#issuecomment-7256501979). Originally posted by [TaynanGT](https://github.com/TaynanGT) on 2026-11-29T13:23:26Z. --- Thanks for addressing both real lints and the unsafe-block documentation. I integrated the changes locally, retaining the existing mapped-image safety check where the branches differed. Full Clippy validation on the consolidated tree is still pending.
Kal0s-design commented 2026-11-29 14:49:14 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by Kal0s-design on 2026-11-29T14:49:14Z.


Small follow-up, f70d0b8: six SAFETY comments in watch.rs came out doubled, the same line twice in a row (around the view and placeholder tests). They're harmless, but since you already integrated this locally you may want to drop them there too. Clippy is still clean with --all-features.

<!-- greyfinch-sync:TaynanGT/Vice-Tay:comment:7257601553 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/442#issuecomment-7257601553). Originally posted by [Kal0s-design](https://github.com/Kal0s-design) on 2026-11-29T14:49:14Z. --- Small follow-up, f70d0b8: six SAFETY comments in `watch.rs` came out doubled, the same line twice in a row (around the view and placeholder tests). They're harmless, but since you already integrated this locally you may want to drop them there too. Clippy is still clean with `--all-features`.
TaynanGT commented 2026-11-29 19:02:07 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by TaynanGT on 2026-11-29T19:02:07Z.


Thanks for catching the duplicate SAFETY comments. I'll keep the cleanup separate from the functional changes and retain the actual safety rationale. Your all-features Clippy result is useful; the consolidated tree still needs its own validation.

<!-- greyfinch-sync:TaynanGT/Vice-Tay:comment:7260953719 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/442#issuecomment-7260953719). Originally posted by [TaynanGT](https://github.com/TaynanGT) on 2026-11-29T19:02:07Z. --- Thanks for catching the duplicate SAFETY comments. I'll keep the cleanup separate from the functional changes and retain the actual safety rationale. Your all-features Clippy result is useful; the consolidated tree still needs its own validation.
TaynanGT commented 2026-11-30 17:06:42 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by TaynanGT on 2026-11-30T17:06:42Z.


main has moved to a new line of the code and everything is now named Vice-Tay, so this PR no longer applies as it is (details in #468). If you'd like this change in, please rebuild it on the current main and open a new PR; I'll review it there.

<!-- greyfinch-sync:TaynanGT/Vice-Tay:comment:7285735847 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/442#issuecomment-7285735847). Originally posted by [TaynanGT](https://github.com/TaynanGT) on 2026-11-30T17:06:42Z. --- `main` has moved to a new line of the code and everything is now named Vice-Tay, so this PR no longer applies as it is (details in #468). If you'd like this change in, please rebuild it on the current `main` and open a new PR; I'll review it there.

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
TaynanGT/Vice-Tay!442
No description provided.