We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8a04b51 commit d10af07Copy full SHA for d10af07
futures-util/src/stream/select_all.rs
@@ -60,7 +60,7 @@ impl<St: Stream + Unpin> SelectAll<St> {
60
/// function will not call `poll` on the submitted stream. The caller must
61
/// ensure that `SelectAll::poll` is called in order to receive task
62
/// notifications.
63
- pub fn push(&mut self, stream: St) {
+ pub fn push(&self, stream: St) {
64
self.inner.push(stream.into_future());
65
}
66
@@ -118,7 +118,7 @@ pub fn select_all<I>(streams: I) -> SelectAll<I::Item>
118
where I: IntoIterator,
119
I::Item: Stream + Unpin
120
{
121
- let mut set = SelectAll::new();
+ let set = SelectAll::new();
122
123
for stream in streams {
124
set.push(stream);
0 commit comments