diff --git a/core/storage/pager.rs b/core/storage/pager.rs index 258188c03..da22387cf 100644 --- a/core/storage/pager.rs +++ b/core/storage/pager.rs @@ -1633,9 +1633,6 @@ impl Pager { IOCompletions::Single(c) => { commit_info.completions.push(c); } - IOCompletions::Many(c) => { - commit_info.completions.extend(c); - } } let mut group = CompletionGroup::new(|_| {}); for c in commit_info.completions.drain(..) { diff --git a/core/types.rs b/core/types.rs index bfcbb004e..00f89118f 100644 --- a/core/types.rs +++ b/core/types.rs @@ -2349,7 +2349,6 @@ impl Cursor { #[must_use] pub enum IOCompletions { Single(Completion), - Many(Vec), } impl IOCompletions { @@ -2357,26 +2356,12 @@ impl IOCompletions { pub fn wait(self, io: &I) -> Result<()> { match self { IOCompletions::Single(c) => io.wait_for_completion(c), - IOCompletions::Many(completions) => { - let mut completions = completions.into_iter(); - while let Some(c) = completions.next() { - let res = io.wait_for_completion(c); - if res.is_err() { - for c in completions { - c.abort(); - } - return res; - } - } - Ok(()) - } } } pub fn finished(&self) -> bool { match self { IOCompletions::Single(c) => c.finished(), - IOCompletions::Many(completions) => completions.iter().all(|c| c.finished()), } } @@ -2384,14 +2369,12 @@ impl IOCompletions { pub fn abort(&self) { match self { IOCompletions::Single(c) => c.abort(), - IOCompletions::Many(completions) => completions.iter().for_each(|c| c.abort()), } } pub fn get_error(&self) -> Option { match self { IOCompletions::Single(c) => c.get_error(), - IOCompletions::Many(completions) => completions.iter().find_map(|c| c.get_error()), } } }