Skip to content

Commit 4fec0b3

Browse files
committed
Should be ExactSizeIterator.
1 parent dbdbf1c commit 4fec0b3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

memapi/src/flamegraph.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,10 @@ where
9494

9595
/// Create iterator over the line-based string format parsed by the inferno
9696
/// crate.
97-
pub fn to_lines(&'a self, to_be_post_processed: bool) -> impl Iterator<Item = String> + 'a {
97+
pub fn to_lines(
98+
&'a self,
99+
to_be_post_processed: bool,
100+
) -> impl ExactSizeIterator<Item = String> + 'a {
98101
let by_call = (&self.data).into_iter();
99102
let mut linecache = LineCacher::default();
100103
by_call.map(move |(callstack, size)| {

0 commit comments

Comments
 (0)