chore: clippy is red on main — approx_constant in engine.rs plus 139 warnings #4
Labels
No labels
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
linux
packaging
performance
question
tech-debt
ui
windows
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
ben/openDither#4
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
cargo clippy --all-targetsdoes not finish onmain: it stops on onedeny-level lint and reports 139 warnings beside it.cargo test,--audit,--controls,--uitestand--selftestare all green, so this is about the next change, not about the app.clippy::approx_constantisdenyby default, so nothing else gets looked at until this is decided.Why it is not a one-line fix
6.28is not a typo ofTAU— it is 0.05 % short, and it sits in the pattern generator, so replacing it moves every pixel of that algorithm by a hair. Eitherconst TURN: f32 = 6.28;, and the lint silenced where it is used with the reason), orTAUis right, and the change should say so and show the render before and after).The second answer needs a picture to compare, so it is a small change with a real decision in it, not a drive-by.
The warnings beside it
139 warnings, 86 of them duplicates of the same pattern (mostly
field_reassign_with_default— 73 hits — plussort_by_key,chunks_exact, needless borrows andlet_and_return). None of them is a bug; the value is that a new warning becomes visible again. Proposed order:6.28(the error), so clippy produces output at all.field_reassign_with_defaultandsort_by_keyin one mechanical pass — a commit of its own, no behaviour change, added to.git-blame-ignore-revs.allowwith a reason next to it.Done when
cargo clippy --all-targets -- -D warningsexits 0 onmain,CONTRIBUTING.mdandAGENTS.mdlist it as a gate next tocargo fmt --check, and the render of the affected algorithm is unchanged — or changed on purpose, with the two pictures in the pull request.