Commit 76fec992 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 49dcaf65
...@@ -103,9 +103,10 @@ func (S *RangeSet) AddRange(r Range) { ...@@ -103,9 +103,10 @@ func (S *RangeSet) AddRange(r Range) {
S.rangev[jhi:]...)...) S.rangev[jhi:]...)...)
tracefRSet("\tmerge [%d:%d]\t-> %s\n", ilo, jhi, S) tracefRSet("\tmerge [%d:%d]\t-> %s\n", ilo, jhi, S)
} }
jhi = -1 // no longer valid
// if [r.lo,r.hi) was outside of any entry - create new entry // if [r.lo,r.hi) was outside of any entry - create new entry
if r.hi_ <= S.rangev[ilo].lo { if r.hi_ < S.rangev[ilo].lo {
S.rangev = append( S.rangev = append(
S.rangev[:ilo], append([]Range{ S.rangev[:ilo], append([]Range{
r}, r},
......
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