github.com/parquet-go/parquet-go@v0.21.1-0.20240501160520-b3c3a0c3ed6f/internal/bitpack/bitpack.go (about) 1 // Package bitpack implements efficient bit packing and unpacking routines for 2 // integers of various bit widths. 3 package bitpack 4 5 // ByteCount returns the number of bytes needed to hold the given bit count. 6 func ByteCount(bitCount uint) int { 7 return int((bitCount + 7) / 8) 8 }