What changed, and why it matters
This commit adds a missing Debug formatting implementation for a six-element decoder helper in the Rust Bitcoin library. It is a routine code-quality fix with no security relevance.
No security action required. Treat as a normal maintenance commit.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The patch implements fmt::Debug for Decoder6<A, B, C, D, E, F>, mirroring existing implementations for other composite decoders. The implementation delegates to self.inner.fmt(f). It does not change parsing logic, input handling, error behavior, or any unsafe code paths.
Changed components
consensus_encoding/src/decode/decoders.rsInspect captured patch +17 / −0
diff --git a/consensus_encoding/src/decode/decoders.rs b/consensus_encoding/src/decode/decoders.rs
index 7716660a..a0ebdfd3 100644
--- a/consensus_encoding/src/decode/decoders.rs
+++ b/consensus_encoding/src/decode/decoders.rs
@@ -640,6 +640,23 @@ where
}
}
+impl<A, B, C, D, E, F> fmt::Debug for Decoder6<A, B, C, D, E, F>
+where
+ A: Decoder + fmt::Debug,
+ B: Decoder + fmt::Debug,
+ C: Decoder + fmt::Debug,
+ D: Decoder + fmt::Debug,
+ E: Decoder + fmt::Debug,
+ F: Decoder + fmt::Debug,
+ A::Output: fmt::Debug,
+ B::Output: fmt::Debug,
+ C::Output: fmt::Debug,
+ D::Output: fmt::Debug,
+ E::Output: fmt::Debug,
+{
+ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { self.inner.fmt(f) }
+}
+
impl<A, B, C, D, E, F> Decoder for Decoder6<A, B, C, D, E, F>
where
A: Decoder,
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.