Skip to content

Commit add94d3

Browse files
committed
Impl FusedIterator for IdxRange
1 parent 665c0cb commit add94d3

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/la-arena/src/lib.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
use std::{
77
cmp, fmt,
88
hash::{Hash, Hasher},
9-
iter::Enumerate,
9+
iter::{Enumerate, FusedIterator},
1010
marker::PhantomData,
1111
ops::{Index, IndexMut, Range, RangeInclusive},
1212
};
@@ -212,6 +212,8 @@ impl<T> DoubleEndedIterator for IdxRange<T> {
212212

213213
impl<T> ExactSizeIterator for IdxRange<T> {}
214214

215+
impl<T> FusedIterator for IdxRange<T> {}
216+
215217
impl<T> fmt::Debug for IdxRange<T> {
216218
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
217219
f.debug_tuple(&format!("IdxRange::<{}>", std::any::type_name::<T>()))

0 commit comments

Comments
 (0)