From 810ee656def2cc0598cfdc6b0d030bbf3491af64 Mon Sep 17 00:00:00 2001 From: ruv Date: Sun, 31 May 2026 10:45:38 -0400 Subject: [PATCH] fix(bfld): gate PrivacyAttestationProof::compute behind std CI `cargo test --no-default-features (baseline regression)` failed with `error: associated function compute is never used` under -D warnings. compute() is only reachable via PrivacyModeRegistry (#[cfg(feature = "std")]); without std there is no caller. Gate the impl to match its only callers. Verified clean under --no-default-features, default, and --features mqtt with RUSTFLAGS=-D warnings. Co-Authored-By: claude-flow --- v2/crates/wifi-densepose-bfld/src/privacy_mode.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/v2/crates/wifi-densepose-bfld/src/privacy_mode.rs b/v2/crates/wifi-densepose-bfld/src/privacy_mode.rs index c11c636a..2354767a 100644 --- a/v2/crates/wifi-densepose-bfld/src/privacy_mode.rs +++ b/v2/crates/wifi-densepose-bfld/src/privacy_mode.rs @@ -132,6 +132,10 @@ pub struct PrivacyAttestationProof { pub hash: [u8; 32], } +// `compute` is only reachable through `PrivacyModeRegistry` (the std-gated +// audit log); without `std` there is no caller, so gate it to match and avoid +// a dead-code error under `--no-default-features` + `-D warnings`. +#[cfg(feature = "std")] impl PrivacyAttestationProof { fn compute(mode: PrivacyMode, prev_hash: [u8; 32]) -> Self { let action_bits = mode.action_bits();