MCPcopy Create free account
hub / github.com/auxten/postgresql-parser / PeekType

Function PeekType

pkg/util/encoding/encoding.go:1293–1298  ·  view source on GitHub ↗

PeekType peeks at the type of the value encoded at the start of b.

(b []byte)

Source from the content-addressed store, hash-verified

1291
1292// PeekType peeks at the type of the value encoded at the start of b.
1293func PeekType(b []byte) Type {
1294 if len(b) >= 1 {
1295 return typMap[b[0]]
1296 }
1297 return Unknown
1298}
1299
1300// slowPeekType is the old implementation of PeekType. It's used to generate
1301// the lookup table for PeekType.

Callers 11

DecodeIfNullFunction · 0.85
DecodeIfNotNullFunction · 0.85
decodeTimeFunction · 0.85
decodeTimeTZFunction · 0.85
DecodeDurationAscendingFunction · 0.85
DecodeDurationDescendingFunction · 0.85
DecodeBitArrayAscendingFunction · 0.85
DecodeBitArrayDescendingFunction · 0.85
prettyPrintFirstValueFunction · 0.85
DecomposeKeyTokensFunction · 0.85
DecodeFloatAscendingFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…