mirror of
https://github.com/fumiama/orbyte.git
synced 2026-06-12 14:10:53 +08:00
feat(pbuf): add api KeepAlive
This commit is contained in:
@@ -117,3 +117,9 @@ func (b Bytes) Slice(from, to int) Bytes {
|
|||||||
nb.dat = b.dat[from:to]
|
nb.dat = b.dat[from:to]
|
||||||
return nb
|
return nb
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// KeepAlive marks Bytes value as reachable.
|
||||||
|
func (b Bytes) KeepAlive() {
|
||||||
|
_ = b.buf
|
||||||
|
_ = b.dat
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user