Skip to content

Commit

Permalink
stream: modify HashMap to StreamMap in example. (#3925)
Browse files Browse the repository at this point in the history
  • Loading branch information
oiovoyo authored Jul 5, 2021
1 parent 37e60fc commit 2e7de1a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tokio-stream/src/stream_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -364,11 +364,11 @@ impl<K, V> StreamMap<K, V> {
/// # Examples
///
/// ```
/// use std::collections::HashMap;
/// use tokio_stream::{StreamMap, pending};
///
/// let mut a = HashMap::new();
/// let mut a = StreamMap::new();
/// assert!(a.is_empty());
/// a.insert(1, "a");
/// a.insert(1, pending::<i32>());
/// assert!(!a.is_empty());
/// ```
pub fn is_empty(&self) -> bool {
Expand Down

1 comment on commit 2e7de1a

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'sync_mpsc'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 2.

Benchmark suite Current: 2e7de1a Previous: 37e60fc Ratio
send_large 69011 ns/iter (± 12545) 28731 ns/iter (± 2921) 2.40

This comment was automatically generated by workflow using github-action-benchmark.

CC: @tokio-rs/maintainers

Please sign in to comment.