Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Ockajak committed Jul 13, 2024
1 parent 8b13afc commit 986f668
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/extensions/util/unfold.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ where
Unfold { state, function }
}

pub(crate) struct Unfold<S, F> {
state: S,
function: F,
}

impl<A, S, F> Iterator for Unfold<S, F>
where
F: FnMut(&mut S) -> Option<A>,
Expand All @@ -16,8 +21,3 @@ where
(self.function)(&mut self.state)
}
}

pub(crate) struct Unfold<S, F> {
state: S,
function: F,
}

0 comments on commit 986f668

Please sign in to comment.