mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-23 00:00:10 +02:00
io: implemented get_ref and get_mut for SyncIoBridge (#7128)
Co-authored-by: ow <[email protected]>
This commit is contained in:
@@ -154,3 +154,15 @@ impl<T: Unpin> SyncIoBridge<T> {
|
||||
self.src
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> AsMut<T> for SyncIoBridge<T> {
|
||||
fn as_mut(&mut self) -> &mut T {
|
||||
&mut self.src
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> AsRef<T> for SyncIoBridge<T> {
|
||||
fn as_ref(&self) -> &T {
|
||||
&self.src
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user