Commit 4f6d5caf authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent eb68c598
......@@ -292,7 +292,7 @@ func (δBtail *ΔBtail) Update(δZ *zodb.EventCommit) (_ ΔB, err error) {
}
for root, δZT := range δZByRoot {
δT, err := δBtail.treediff(ctx, root, δZT, zconnOld, zconnNew)
δT, err := treediff(ctx, root, δZT, zconnOld, zconnNew)
if err != nil {
return ΔB{}, err
}
......@@ -327,7 +327,7 @@ func (δBtail *ΔBtail) Update(δZ *zodb.EventCommit) (_ ΔB, err error) {
//
// XXX only for tracked
// δZT is δZ/T - subset of δZ(old..new) that touches tracked nodes of T.
func (δBtail *ΔBtail) treediff(ctx context.Context, root zodb.Oid, δZT SetOid, zconnOld, zconnNew *zodb.Connection) (δT map[Key]Value, err error) {
func treediff(ctx context.Context, root zodb.Oid, δZT SetOid, zconnOld, zconnNew *zodb.Connection) (δT map[Key]Value, err error) {
defer xerr.Contextf(&err, "treediff %s..%s %s", zconnOld.At(), zconnNew.At(), root)
// XXX zconnX -> a, b ?
......@@ -353,7 +353,9 @@ func (δBtail *ΔBtail) treediff(ctx context.Context, root zodb.Oid, δZT SetOid
}
// FIXME -> merge (VDEL vs add)
// XXX no - not needed here - changes cannot migrate in between two disconnected subtrees
// XXX no - not needed here - keys cannot migrate in between two disconnected subtrees
// DEL k -> Tkextra += k
// +k -> Tkextra -= k
for k,v := range δtop {
δT[k] = v
}
......
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