Commit 274d6fbb authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 32deda2c
...@@ -53,7 +53,10 @@ func (S *RangeSet) Del(k Key) { ...@@ -53,7 +53,10 @@ func (S *RangeSet) Del(k Key) {
S.DelRange(Range{lo: k, hi_: k}) S.DelRange(Range{lo: k, hi_: k})
} }
// XXX Has? // Has returns whether key k belongs to the set.
func (S *RangeSet) Has(k Key) bool {
return S.HasRange(Range{lo: k, hi_: k})
}
// AddRange adds Range r to the set. // AddRange adds Range r to the set.
...@@ -231,6 +234,10 @@ func (S *RangeSet) DelRange(r Range) { ...@@ -231,6 +234,10 @@ func (S *RangeSet) DelRange(r Range) {
// done // done
} }
// HasRange returns whether all keys from Range r belong to the set.
func (S *RangeSet) HasRange(r Range) bool {
panic("TODO")
}
// Union returns RangeSet(A.keys | B.keys). // Union returns RangeSet(A.keys | B.keys).
......
...@@ -533,8 +533,8 @@ func diffT(ctx context.Context, A, B *Tree, δZTC SetOid, trackSet PPTreeSubSet) ...@@ -533,8 +533,8 @@ func diffT(ctx context.Context, A, B *Tree, δZTC SetOid, trackSet PPTreeSubSet)
Bktodo := func(lo, hi_ Key) { // XXX func(r KeyRange) Bktodo := func(lo, hi_ Key) { // XXX func(r KeyRange)
panic("TODO") panic("TODO")
/* XXX reenable /* XXX reenable
if !Bkdone.HasRange(r) {
δtodo := r.Difference(Bkdone) // XXX name δtodo := r.Difference(Bkdone) // XXX name
if !δtodo.Empty() {
tracef(" Bkq <- %s\n", δtodo) tracef(" Bkq <- %s\n", δtodo)
Bkqueue.UnionInplace(δtodo) Bkqueue.UnionInplace(δtodo)
} }
......
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