summaryrefslogtreecommitdiffstats
path: root/tokio/src/stream/stream_map.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tokio/src/stream/stream_map.rs')
-rw-r--r--tokio/src/stream/stream_map.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/tokio/src/stream/stream_map.rs b/tokio/src/stream/stream_map.rs
index 8539e4da..9fed3c19 100644
--- a/tokio/src/stream/stream_map.rs
+++ b/tokio/src/stream/stream_map.rs
@@ -156,7 +156,7 @@ use std::task::{Context, Poll};
/// }
/// }
/// ```
-#[derive(Debug, Default)]
+#[derive(Debug)]
pub struct StreamMap<K, V> {
/// Streams stored in the map
entries: Vec<(K, V)>,
@@ -513,6 +513,12 @@ where
}
}
+impl<K, V> Default for StreamMap<K, V> {
+ fn default() -> Self {
+ Self::new()
+ }
+}
+
impl<K, V> Stream for StreamMap<K, V>
where
K: Clone + Unpin,