Skip to content

Commit e307fde

Browse files
committed
Move TransmitBuf::as_mut_slice
This should be together with the other &mut self methods.
1 parent f2ecc76 commit e307fde

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

quinn-proto/src/connection/transmit_buf.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,11 @@ impl<'a> TransmitBuf<'a> {
145145
self.buf.limit(self.buf_capacity)
146146
}
147147

148+
/// Returns the already written bytes in the buffer
149+
pub(super) fn as_mut_slice(&mut self) -> &mut [u8] {
150+
self.buf.as_mut_slice()
151+
}
152+
148153
/// Returns the GSO segment size
149154
///
150155
/// This is also the maximum size datagrams are allowed to be. The first and last
@@ -190,9 +195,4 @@ impl<'a> TransmitBuf<'a> {
190195
pub(super) fn len(&self) -> usize {
191196
self.buf.len()
192197
}
193-
194-
/// Returns the already written bytes in the buffer
195-
pub(super) fn as_mut_slice(&mut self) -> &mut [u8] {
196-
self.buf.as_mut_slice()
197-
}
198198
}

0 commit comments

Comments
 (0)