MCPcopy Create free account
hub / github.com/PostHog/duckgres / decodeBool

Function decodeBool

server/types.go:913–918  ·  view source on GitHub ↗
(data []byte)

Source from the content-addressed store, hash-verified

911}
912
913func decodeBool(data []byte) (bool, error) {
914 if len(data) < 1 {
915 return false, fmt.Errorf("insufficient data for bool: got %d bytes, need 1", len(data))
916 }
917 return data[0] != 0, nil
918}
919
920func decodeInt2(data []byte) (int16, error) {
921 if len(data) < 2 {

Callers 3

TestDecodeBoolFunction · 0.85
decodeBinaryCopyFunction · 0.85
decodeBinaryFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestDecodeBoolFunction · 0.68