Merge remote-tracking branch 'origin' into feat/safe-put
Some checks failed
CI / Check PR Title (pull_request) Successful in 31s
CI / Go Lint (pull_request) Successful in 52s
CI / Markdown Lint (pull_request) Successful in 34s
CI / Makefile Lint (pull_request) Successful in 50s
CI / Unit Tests (pull_request) Successful in 48s
CI / Fuzz Tests (pull_request) Failing after 41s
CI / Mutation Tests (pull_request) Successful in 1m3s
Some checks failed
CI / Check PR Title (pull_request) Successful in 31s
CI / Go Lint (pull_request) Successful in 52s
CI / Markdown Lint (pull_request) Successful in 34s
CI / Makefile Lint (pull_request) Successful in 50s
CI / Unit Tests (pull_request) Successful in 48s
CI / Fuzz Tests (pull_request) Failing after 41s
CI / Mutation Tests (pull_request) Successful in 1m3s
This commit is contained in:
@@ -9,7 +9,7 @@ import "fmt"
|
||||
const DefaultCapacity uint64 = 16
|
||||
|
||||
// DefaultGrowthFactor is the standard resize multiplier for a [Table]. Most
|
||||
// hash table implementations use 2.
|
||||
// implementations use 2.
|
||||
const DefaultGrowthFactor uint64 = 2
|
||||
|
||||
// defaultMinimumLoad is the default lowest acceptable occupancy of a [Table].
|
||||
@@ -31,10 +31,10 @@ type settings struct {
|
||||
}
|
||||
|
||||
// An Option modifies the settings of a [Table]. It is used in its constructors
|
||||
// like [NewTable], for example.
|
||||
// like [New], for example.
|
||||
type Option func(*settings)
|
||||
|
||||
// Capacity modifies the starting capacity of each bucket of the [Table]. The
|
||||
// Capacity modifies the starting capacity of each subtable of the [Table]. The
|
||||
// value must be non-negative.
|
||||
func Capacity(value int) Option {
|
||||
if value < 0 {
|
||||
|
||||
Reference in New Issue
Block a user