Skip to content

Commit

Permalink
Address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
a1phyr committed Nov 22, 2023
1 parent dee5c03 commit 798ba9f
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/raw/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3850,9 +3850,10 @@ impl<T> RawIterRange<T> {
/// Folds every element into an accumulator by applying an operation,
/// returning the final result.
///
/// `fold_impl()` takes three arguments: a number of items in the table, an initial value,
/// and a closure with two arguments: an 'accumulator', and an element. The closure
/// returns the value that the accumulator should have for the next iteration.
/// `fold_impl()` takes three arguments: the number of items remaining in
/// the iterator, an initial value, and a closure with two arguments: an
/// 'accumulator', and an element. The closure returns the value that the
/// accumulator should have for the next iteration.
///
/// The initial value is the value the accumulator will have on the first call.
///
Expand All @@ -3877,10 +3878,6 @@ impl<T> RawIterRange<T> {
where
F: FnMut(B, Bucket<T>) -> B,
{
if n == 0 {
return acc;
}

loop {
while let Some(index) = self.current_group.next() {
// The returned `index` will always be in the range `0..Group::WIDTH`,
Expand Down

0 comments on commit 798ba9f

Please sign in to comment.