mirror of
https://github.com/etcd-io/bbolt.git
synced 2025-04-27 13:12:47 +00:00
17 lines
248 B
Go
17 lines
248 B
Go
package bolt
|
|
|
|
import (
|
|
"unsafe"
|
|
)
|
|
|
|
const (
|
|
bigNode = 0x01
|
|
subNode = 0x02
|
|
dupNode = 0x04
|
|
)
|
|
|
|
// key returns a byte slice that of the key data.
|
|
func (n *branchNode) key() []byte {
|
|
return (*[MaxKeySize]byte)(unsafe.Pointer(&n.data))[:n.keySize]
|
|
}
|