Commit 74bf1db8 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent c10d0b65
......@@ -390,11 +390,6 @@ func (δBtail *ΔBtail) Tail() zodb.Tid { return δBtail.δZtail.Tail() }
//
// XXX catch cycles on add?
func (δBtail *ΔBtail) Track(key Key, keyPresent bool, path []Node) error { // XXX Tree|Bucket; path[0] = root
// l := len(path)
// if l == 0 {
// panic("empty path")
// }
// XXX assert Tree Tree ... Tree Bucket
root := path[0].(*Tree).POid()
......@@ -404,40 +399,6 @@ func (δBtail *ΔBtail) Track(key Key, keyPresent bool, path []Node) error { //
δBtail.trackIdx.AddNodePath(path)
// parent := zodb.InvalidOid
// var ptrack *nodeTrack = nil
// var track *nodeTrack // XXX kill here
// var oldTrack bool
// for _, node := range path { // XXX -> trackIndex.AddPath(path) ?
// oid := node.POid()
// // XXX skip InvalidOid ?
// // InvalidOid means embedded bucket - e.g. T/B1:a with bucket not having its own oid.
//
// track, oldTrack = δBtail.trackIdx[oid]
// if !oldTrack {
// track = &nodeTrack{parent: parent, nchild: 0} // XXX
// /*
// if i == l-1 { // leaf
// track.holes = SetKey{}
// }
// */
// δBtail.trackIdx[oid] = track
// // XXX .trackNew += oid
// }
// if track.parent != parent {
// // XXX -> error (e.g. due to corrupt data in ZODB)
// panicf("node %s is reachable from multiple parents: %s %s",
// oid, track.parent, parent)
// }
//
// if ptrack != nil {
// ptrack.nchild++
// }
//
// parent = oid
// ptrack = track
// }
// track is track of path[-1] (i.e. leaf)
// remember missing keys in track of leaf node (bucket or top-level ø tree)
......
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