@@ -211,7 +211,7 @@ fn capacity_to_buckets(cap: usize) -> Option<usize> {
211
211
212
212
// Any overflows will have been caught by the checked_mul. Also, any
213
213
// rounding errors from the division above will be cleaned up by
214
- // next_power_of_two (which can't overflow because of the previous divison ).
214
+ // next_power_of_two (which can't overflow because of the previous division ).
215
215
Some ( adjusted_cap. next_power_of_two ( ) )
216
216
}
217
217
@@ -1236,7 +1236,7 @@ impl<A: Allocator + Clone> RawTableInner<A> {
1236
1236
// EMPTY entries. These will unfortunately trigger a
1237
1237
// match, but once masked may point to a full bucket that
1238
1238
// is already occupied. We detect this situation here and
1239
- // perform a second scan starting at the begining of the
1239
+ // perform a second scan starting at the beginning of the
1240
1240
// table. This second scan is guaranteed to find an empty
1241
1241
// slot (due to the load factor) before hitting the trailing
1242
1242
// control bytes (containing EMPTY).
@@ -1469,7 +1469,7 @@ impl<A: Allocator + Clone> RawTableInner<A> {
1469
1469
//
1470
1470
// Note that in this context `leading_zeros` refers to the bytes at the
1471
1471
// end of a group, while `trailing_zeros` refers to the bytes at the
1472
- // begining of a group.
1472
+ // beginning of a group.
1473
1473
let ctrl = if empty_before. leading_zeros ( ) + empty_after. trailing_zeros ( ) >= Group :: WIDTH {
1474
1474
DELETED
1475
1475
} else {
@@ -1886,7 +1886,7 @@ impl<T> RawIter<T> {
1886
1886
/// For the iterator to remain valid, this method must be called once
1887
1887
/// for each insert before `next` is called again.
1888
1888
///
1889
- /// This method does not guarantee that an insertion of a bucket witha greater
1889
+ /// This method does not guarantee that an insertion of a bucket with a greater
1890
1890
/// index than the last one yielded will be reflected in the iterator.
1891
1891
///
1892
1892
/// This method should be called _after_ the given insert is made.
@@ -1938,7 +1938,7 @@ impl<T> RawIter<T> {
1938
1938
// If it did, we're done.
1939
1939
// - Otherwise, update the iterator cached group so that it won't
1940
1940
// yield a to-be-removed bucket, or _will_ yield a to-be-added bucket.
1941
- // We'll also need ot update the item count accordingly.
1941
+ // We'll also need to update the item count accordingly.
1942
1942
if let Some ( index) = self . iter . current_group . lowest_set_bit ( ) {
1943
1943
let next_bucket = self . iter . data . next_n ( index) ;
1944
1944
if b. as_ptr ( ) > next_bucket. as_ptr ( ) {
0 commit comments