Start on implementing filtering support for Cursor::prev

This commit is contained in:
Antonio Scandurra
2022-03-15 15:13:23 +01:00
parent 7c6fe56347
commit 45ce503afd
5 changed files with 65 additions and 91 deletions
+3 -3
View File
@@ -242,10 +242,10 @@ impl<T: Item> SumTree<T> {
extent
}
pub fn summary(&self) -> T::Summary {
pub fn summary(&self) -> &T::Summary {
match self.0.as_ref() {
Node::Internal { summary, .. } => summary.clone(),
Node::Leaf { summary, .. } => summary.clone(),
Node::Internal { summary, .. } => summary,
Node::Leaf { summary, .. } => summary,
}
}