Skip to content

Commit f6b3d8f

Browse files
authored
Auto merge of #288 - negator:patch-2, r=jdm
FusedStream for IpcStream Implements `FusedStream` trait for `IpcStream`, so allow the usage of the [`select!` macro](https://docs.rs/futures/0.3.18/futures/stream/trait.FusedStream.html).
2 parents f700ea3 + 5582ad5 commit f6b3d8f

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/asynch.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,3 +112,12 @@ where
112112
}
113113
}
114114
}
115+
116+
impl<T> FusedStream for IpcStream<T>
117+
where
118+
T: for<'de> Deserialize<'de> + Serialize,
119+
{
120+
fn is_terminated(&self) -> bool {
121+
self.0.is_terminated()
122+
}
123+
}

0 commit comments

Comments
 (0)