Context
The pre-commit hook currently runs cargo clippy --workspace -- -D warnings which lints only lib + bin targets by default. This misses lints in tests, benches, and examples — caught by CI but only after a push round-trip.
Concrete recent example: PR #79 (1a7f8c4) passed the local hook but failed CI on crates/embed/tests/simd_edge_cases.rs:591:26 (private field access in integration test after field privatization). The local hook didn't catch it because integration tests aren't part of default clippy scope.
Proposal
Tighten the hook:
-cargo clippy --workspace -- -D warnings
+cargo clippy --workspace --all-targets -- -D warnings
Blocker
--all-targets currently fails on lattice-tune lib tests with 2 pre-existing lints:
error: redundant_closure_for_method_calls (location TBD, need to capture)
- One other (TBD)
These need to be fixed first or the hook becomes a wall blocking all commits.
Plan
- Run
cargo clippy --workspace --all-targets -- -D warnings locally, capture full error list
- Fix all pre-existing
--all-targets lints across the workspace (probably 5-20 errors total)
- Land the hook tightening as part of the cleanup PR
Priority
P2 — annoying but not blocking. Each missed-at-CI lint costs ~2 min push-fail-fix-push cycle.
Context
The pre-commit hook currently runs
cargo clippy --workspace -- -D warningswhich lints onlylib+bintargets by default. This misses lints in tests, benches, and examples — caught by CI but only after a push round-trip.Concrete recent example: PR #79 (1a7f8c4) passed the local hook but failed CI on
crates/embed/tests/simd_edge_cases.rs:591:26(private field access in integration test after field privatization). The local hook didn't catch it because integration tests aren't part of default clippy scope.Proposal
Tighten the hook:
Blocker
--all-targetscurrently fails onlattice-tunelib tests with 2 pre-existing lints:error: redundant_closure_for_method_calls(location TBD, need to capture)These need to be fixed first or the hook becomes a wall blocking all commits.
Plan
cargo clippy --workspace --all-targets -- -D warningslocally, capture full error list--all-targetslints across the workspace (probably 5-20 errors total)Priority
P2 — annoying but not blocking. Each missed-at-CI lint costs ~2 min push-fail-fix-push cycle.