Source File
log.go
Belonging Package
github.com/jackc/puddle/v2
package puddleimporttype ints interface {int | int8 | int16 | int32 | int64 | uint | uint8 | uint16 | uint32 | uint64}// log2Int returns log2 of an integer. This function panics if val < 0. For val// == 0, returns 0.func [ ints]( ) uint8 {if <= 0 {panic("log2 of non-positive number does not exist")}return log2IntRange(, 0, uint8(8*unsafe.Sizeof()))}func [ ints]( , , uint8) uint8 {:= -if == 1 {return}:= + /2:= (1) <<if > {return (, , )} else {return (, , )}}
The pages are generated with Golds v0.7.6. (GOOS=linux GOARCH=amd64)