code: func (tr Ranges) addRangeInPlace(r Range) {
  	if r.IsEmpty() {
  		return
  	}
  
  	e := tr.findFirstNotBefore(r)
  	for e != nil {
  		lr := e.Value.(Range)
  		ne := e.Next()
  		if !lr.Overlaps(r) {
  			break
  		}
  		r = r.Merge(lr)
  		tr.sortedRanges.Remove(e)
  		e = ne
  	}
  	if e == nil {
  		tr.sortedRanges.PushBack(r)
  		return
  	}
  	tr.sortedRanges.InsertBefore(r, e)
  }
docs: // addRangeInPlace adds r to tr in place without creating a new copy.