Skip to content

Commit

Permalink
Clippy clippy joy joy
Browse files Browse the repository at this point in the history
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
  • Loading branch information
Matthias Wahl authored and mfelsche committed Mar 25, 2021
1 parent c02011a commit 2c6f0da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/source/cb.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,12 @@ impl ReceivedCbs {

fn missing_ids(&self) -> Vec<u64> {
let mut all_ids: Vec<u64> = self.ack.iter().chain(self.fail.iter()).copied().collect();
all_ids.sort();
all_ids.sort_unstable();

all_ids
.windows(2)
.filter_map(|window| match window {
&[low, hi] if hi - low > 1 => Some((low + 1)..hi),
[low, hi] if hi - low > 1 => Some((low + 1)..*hi),
_ => None,
})
.flatten()
Expand Down

0 comments on commit 2c6f0da

Please sign in to comment.