Commit 393f478
fix(sysres): use then_some for the Windows memory counters
`bool::then` with a closure that only reads a field is what clippy's
`unnecessary_lazy_evaluations` rejects, and it failed the Windows leg -- the one
matrix combination (`comms shells` on windows-latest) that neither the macOS nor
the Linux legs compile. Both call sites are eager field reads with no side
effects, so `then_some` is identical in behaviour.
Verified by cross-compiling rather than by inference: `cargo clippy --target
x86_64-pc-windows-gnu --workspace --all-targets --tests --features "comms shells"
-- -D warnings` now exits 0. That is not CI's MSVC toolchain, but it compiles the
same `#[cfg(windows)]` paths that were failing.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XWgvgjgdoPq3TjCxPyfbws1 parent 23eedc3 commit 393f478
1 file changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
460 | 460 | | |
461 | 461 | | |
462 | 462 | | |
463 | | - | |
| 463 | + | |
464 | 464 | | |
465 | 465 | | |
466 | 466 | | |
| |||
552 | 552 | | |
553 | 553 | | |
554 | 554 | | |
555 | | - | |
| 555 | + | |
556 | 556 | | |
557 | 557 | | |
558 | 558 | | |
| |||
0 commit comments