(range: TextRange | TextRange[] | undefined)
| 31 | } |
| 32 | |
| 33 | extend(range: TextRange | TextRange[] | undefined) { |
| 34 | if (range) { |
| 35 | if (Array.isArray(range)) { |
| 36 | range.forEach(r => { |
| 37 | this.extend(r); |
| 38 | }); |
| 39 | } else { |
| 40 | if (range.start < this.start) { |
| 41 | this.length += this.start - range.start; |
| 42 | this.start = range.start; |
| 43 | } |
| 44 | |
| 45 | if (range.end > this.end) { |
| 46 | this.length += range.end - this.end; |
| 47 | } |
| 48 | } |
| 49 | } |
| 50 | } |
| 51 | } |
no test coverage detected