Closed vvvviiv closed 11 months ago
Hello, I noticed that the Debug trait isn't implemented for the IdleTimeout struct in quinn-proto/src/config.rs. I'm trying to fix it, but I'm uncertain about the preferred style for debugging messages.
Debug
IdleTimeout
quinn-proto/src/config.rs
I have come up with two ways to fix it:
Simply use the Debug derive macro.
#[derive(Default, Debug, Copy, Clone, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct IdleTimeout(VarInt);
Use the same style as the VarInt struct in quinn-proto/src/varint.rs.
VarInt
quinn-proto/src/varint.rs
impl fmt::Debug for IdleTimeout { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { self.0.fmt(f) } }
Or am I missing something that blocks the implementation? Please let me know if there is anything else that needs to be done to implement this.
Either would be fine; personally I lean towards the latter to reduce noise, but I don't think we need to overthink this.
Hello, I noticed that the
Debug
trait isn't implemented for theIdleTimeout
struct inquinn-proto/src/config.rs
. I'm trying to fix it, but I'm uncertain about the preferred style for debugging messages.I have come up with two ways to fix it:
Simply use the
Debug
derive macro.Use the same style as the
VarInt
struct inquinn-proto/src/varint.rs
.Or am I missing something that blocks the implementation? Please let me know if there is anything else that needs to be done to implement this.