MCPcopy Create free account
hub / github.com/CodingGay/BlackDex / FirstAvailableSlot

Method FirstAvailableSlot

Bcore/src/main/cpp/base/hash_set.h:641–650  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

639 }
640
641 ALWAYS_INLINE size_t FirstAvailableSlot(size_t index) const {
642 DCHECK_LT(index, NumBuckets()); // Don't try to get a slot out of range.
643 size_t non_empty_count = 0;
644 while (!emptyfn_.IsEmpty(data_[index])) {
645 index = NextIndex(index);
646 non_empty_count++;
647 DCHECK_LE(non_empty_count, NumBuckets()); // Don't loop forever.
648 }
649 return index;
650 }
651
652 // Return new offset.
653 template <typename Elem>

Callers

nothing calls this directly

Calls 1

IsEmptyMethod · 0.45

Tested by

no test coverage detected