Documentation
¶
Index ¶
Constants ¶
View Source
const ( // DefaultMaxLoad is the default value for the load factor. // It can be changed with `MaxLoad`. This value is a // trade-off of runtime and memory consumption. DefaultMaxLoad = 0.7 // DefaultSize is the default for the amount before // the first resize happens. DefaultSize = 4 )
Variables ¶
View Source
var ErrOutOfRange = errors.New("out of range")
ErrOutOfRange signals an out of range request.
Functions ¶
func NextPowerOf2 ¶
NextPowerOf2 is a fast computation of 2^x see: https://stackoverflow.com/questions/466204/rounding-up-to-next-power-of-2
Types ¶
Click to show internal directories.
Click to hide internal directories.