mirror of https://github.com/hak5/bolt.git
undo page.go changes
parent
4dbd354a8d
commit
51568b52df
4
page.go
4
page.go
|
@ -63,7 +63,7 @@ func (p *page) leafPageElement(index uint16) *leafPageElement {
|
|||
|
||||
// leafPageElements retrieves a list of leaf nodes.
|
||||
func (p *page) leafPageElements() []leafPageElement {
|
||||
return ((*[maxNodesPerPage]leafPageElement)(unsafe.Pointer(&p.ptr)))[:p.count]
|
||||
return ((*[maxNodesPerPage]leafPageElement)(unsafe.Pointer(&p.ptr)))[:]
|
||||
}
|
||||
|
||||
// branchPageElement retrieves the branch node by index
|
||||
|
@ -73,7 +73,7 @@ func (p *page) branchPageElement(index uint16) *branchPageElement {
|
|||
|
||||
// branchPageElements retrieves a list of branch nodes.
|
||||
func (p *page) branchPageElements() []branchPageElement {
|
||||
return ((*[maxNodesPerPage]branchPageElement)(unsafe.Pointer(&p.ptr)))[:p.count]
|
||||
return ((*[maxNodesPerPage]branchPageElement)(unsafe.Pointer(&p.ptr)))[:]
|
||||
}
|
||||
|
||||
// dump writes n bytes of the page to STDERR as hex output.
|
||||
|
|
Loading…
Reference in New Issue