From 510e152353fe96f062260ac22c6240de620c612e Mon Sep 17 00:00:00 2001 From: Sam Rijs Date: Thu, 7 Jun 2018 20:45:45 +1000 Subject: [PATCH] regex: implement size_hint for set match iterators --- src/re_set.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/re_set.rs b/src/re_set.rs index 66b01512ef..cfca0ea405 100644 --- a/src/re_set.rs +++ b/src/re_set.rs @@ -295,6 +295,10 @@ impl Iterator for SetMatchesIntoIter { } } } + + fn size_hint(&self) -> (usize, Option) { + self.0.size_hint() + } } impl DoubleEndedIterator for SetMatchesIntoIter { @@ -331,6 +335,10 @@ impl<'a> Iterator for SetMatchesIter<'a> { } } } + + fn size_hint(&self) -> (usize, Option) { + self.0.size_hint() + } } impl<'a> DoubleEndedIterator for SetMatchesIter<'a> {