Skip to content

Commit

Permalink
specify ExactSizeIterator for Space::elements()
Browse files Browse the repository at this point in the history
  • Loading branch information
m4rch3n1ng authored and Drakulix committed Sep 10, 2024
1 parent 85268cd commit f364c73
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/desktop/space/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ impl<E: SpaceElement + PartialEq> Space<E> {
}

/// Iterate elements in z-order back to front
pub fn elements(&self) -> impl DoubleEndedIterator<Item = &E> {
pub fn elements(&self) -> impl DoubleEndedIterator<Item = &E> + ExactSizeIterator {
self.elements.iter().map(|e| &e.element)
}

Expand Down

0 comments on commit f364c73

Please sign in to comment.