MCPcopy
hub / github.com/grafana/dskit / yoloBuf

Function yoloBuf

ring/shard/shard.go:46–48  ·  view source on GitHub ↗

yoloBuf will return an unsafe pointer to a string, as the name yolo.yoloBuf implies use at your own risk.

(s string)

Source from the content-addressed store, hash-verified

44
45// yoloBuf will return an unsafe pointer to a string, as the name yolo.yoloBuf implies use at your own risk.
46func yoloBuf(s string) []byte {
47 return unsafe.Slice(unsafe.StringData(s), len(s))
48}

Callers 2

ShuffleShardSeedFunction · 0.85
TestYoloBufFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestYoloBufFunction · 0.68