Commit ae736e82 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 6a414e2d
...@@ -508,7 +508,6 @@ func (prs *rangeSplit) Expand(rnode *nodeInRange) (children rangeSplit) { ...@@ -508,7 +508,6 @@ func (prs *rangeSplit) Expand(rnode *nodeInRange) (children rangeSplit) {
// [len(ev)].Key = +∞ ; should be assumed so // [len(ev)].Key = +∞ ; should be assumed so
tree := rnode.node.(*Tree) tree := rnode.node.(*Tree)
treev := tree.Entryv() treev := tree.Entryv()
// fmt.Printf("E treev: %v\n", treev)
children = make(rangeSplit, 0, len(treev)+1) children = make(rangeSplit, 0, len(treev)+1)
for i := range treev { for i := range treev {
lo := rnode.lo lo := rnode.lo
...@@ -517,7 +516,7 @@ func (prs *rangeSplit) Expand(rnode *nodeInRange) (children rangeSplit) { ...@@ -517,7 +516,7 @@ func (prs *rangeSplit) Expand(rnode *nodeInRange) (children rangeSplit) {
} }
hi_ := rnode.hi_ hi_ := rnode.hi_
if i < len(treev)-1 { if i < len(treev)-1 {
hi_ = treev[i+1].Key()-1 // NOTE -1 hi_ = treev[i+1].Key()-1 // NOTE -1 because it is hi_] not hi)
} }
children = append(children, &nodeInRange{ children = append(children, &nodeInRange{
...@@ -527,8 +526,6 @@ func (prs *rangeSplit) Expand(rnode *nodeInRange) (children rangeSplit) { ...@@ -527,8 +526,6 @@ func (prs *rangeSplit) Expand(rnode *nodeInRange) (children rangeSplit) {
}) })
} }
// fmt.Printf("E children: %s\n", children)
// del[i]; insert(@i, children) // del[i]; insert(@i, children)
*prs = append(rs[:i], append(children, rs[i+1:]...)...) *prs = append(rs[:i], append(children, rs[i+1:]...)...)
return children return children
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment