File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -1470,6 +1470,17 @@ impl<T> Iterator for RawIterRange<T> {
14701470impl < T > FusedIterator for RawIterRange < T > { }
14711471
14721472/// Iterator which returns a raw pointer to every full bucket in the table.
1473+ ///
1474+ /// For maximum flexibility this iterator is not bound by a lifetime, but you
1475+ /// must observe several rules when using it:
1476+ /// - You must not free the hash table while iterating (including via growing/shrinking).
1477+ /// - It is fine to erase a bucket that has been yielded by the iterator.
1478+ /// - Erasing a bucket that has not yet been yielded by the iterator may still
1479+ /// result in the iterator yielding that bucket (unless `reflect_remove` is called).
1480+ /// - It is unspecified whether an element inserted after the iterator was
1481+ /// created will be yielded by that iterator (unless `reflect_insert` is called).
1482+ /// - The order in which the iterator yields bucket is unspecified and may
1483+ /// change in the future.
14731484pub struct RawIter < T > {
14741485 pub ( crate ) iter : RawIterRange < T > ,
14751486 items : usize ,
You can’t perform that action at this time.
0 commit comments