docs: added comments to give context to functions
Some checks failed
CI / Makefile Lint (pull_request) Successful in 21s
CI / Go Lint (pull_request) Failing after 12s
CI / Unit Tests (pull_request) Successful in 14s
CI / Fuzz Tests (pull_request) Successful in 1m14s
CI / Mutation Tests (pull_request) Successful in 53s

This commit is contained in:
2026-03-19 21:06:12 -04:00
parent bd3f0aad04
commit 0c81bc5cae
2 changed files with 9 additions and 0 deletions

View File

@@ -17,6 +17,8 @@ type bucket[K, V any] struct {
compare EqualFunc[K]
}
// location determines where in the bucket a certain key would be placed. If the
// capacity is 0, this will panic.
func (b bucket[K, V]) location(key K) uint64 {
return b.hash(key) % b.capacity
}