# Clippy is run with `-D warnings` in CI (CLAUDE.md §10.4), so every lint we # enable here is a build failure. Only turn on lints we are willing to fix. [lints.rust] # Silent truncation of a u64 millisecond count into a u32 is a real bug class in # this codebase (usage counters, monotonic deltas). Make it impossible to miss. integer_conversions = "deny" [lints.clippy] # Engine code is mostly pure data transformation; `&self` everywhere reads better # than `&mut self` and avoids accidental aliasing bugs across the FFI boundary. needless_pass_by_ref_mut = "warn" # Large enum variants waste stack in the hot evaluate() path. large_enum_variant = "warn" # Every OS call returns Result; we handle them all, but catch `.unwrap()` slips. unwrap_used = "deny" expect_used = "deny" # Panicking in release builds is a last resort — see CLAUDE.md §0.5. panic = "deny" # Prefer clarity over micro-optimisation; perf budgets in §5 are measured with # real benchmarks, not by guessing at clever rewrites. too_many_arguments = "warn"