MCPcopy
hub / github.com/google/uuid / xtob

Function xtob

util.go:39–43  ·  view source on GitHub ↗

xtob converts hex characters x1 and x2 into a byte.

(x1, x2 byte)

Source from the content-addressed store, hash-verified

37
38// xtob converts hex characters x1 and x2 into a byte.
39func xtob(x1, x2 byte) (byte, bool) {
40 b1 := xvalues[x1]
41 b2 := xvalues[x2]
42 return (b1 << 4) | b2, b1 != 255 && b2 != 255
43}

Callers 3

ParseFunction · 0.85
ParseBytesFunction · 0.85
ValidateFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected