Commit 51359ef1 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent bc1b465f
...@@ -520,6 +520,8 @@ func diffT(ctx context.Context, a, b *Tree, δZTC SetOid, trackIdx map[zodb.Oid] ...@@ -520,6 +520,8 @@ func diffT(ctx context.Context, a, b *Tree, δZTC SetOid, trackIdx map[zodb.Oid]
defer b.PDeactivate() defer b.PDeactivate()
bv = b.Entryv() // key↑ bv = b.Entryv() // key↑
} }
fmt.Printf(" av: %s\n", strVTreeEntry(av))
fmt.Printf(" bv: %v\n", strVTreeEntry(bv))
δ = map[Key]ΔValue{} δ = map[Key]ΔValue{}
...@@ -995,3 +997,22 @@ func δassertSlice(δ interface { Head() zodb.Tid; Tail() zodb.Tid }, lo, hi zod ...@@ -995,3 +997,22 @@ func δassertSlice(δ interface { Head() zodb.Tid; Tail() zodb.Tid }, lo, hi zod
panicf("invalid slice: (%s, %s]; (tail, head] = (%s, %s]", lo, hi, tail, head) panicf("invalid slice: (%s, %s]; (tail, head] = (%s, %s]", lo, hi, tail, head)
} }
} }
func strVTreeEntry(v []TreeEntry) string {
s := ""
for _, e := range v {
if s != "" {
s += " "
}
c := e.Child()
ckind := "?"
switch c.(type) {
case *Tree: ckind = "T"
case *Bucket: ckind = "B"
}
s += fmt.Sprintf("%v %s%s", e.Key(), ckind, c.POid())
}
return s
}
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