Skip to content

Commit 7470c9b

Browse files
committed
swarm: Drop Debug impl for OneShotHandler to keep scope minimal
1 parent 6b5bea5 commit 7470c9b

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

swarm/src/handler/one_shot.rs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -112,18 +112,7 @@ where
112112
}
113113
}
114114

115-
impl<TInbound, TOutbound, TEvent> std::fmt::Debug for OneShotHandler<TInbound, TOutbound, TEvent>
116-
where
117-
TOutbound: OutboundUpgradeSend,
118-
{
119-
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
120-
f.debug_struct("OneShotHandler")
121-
.field("pending_requests", &self.pending_requests())
122-
.field("dial_negotiated", &self.dial_negotiated)
123-
.field("dial_queue_len", &self.dial_queue.len())
124-
.finish()
125-
}
126-
}
115+
// Debug intentionally not implemented to keep handler lean at runtime.
127116

128117
impl<TInbound, TOutbound, TEvent> ConnectionHandler for OneShotHandler<TInbound, TOutbound, TEvent>
129118
where

0 commit comments

Comments
 (0)