(pos, end)
| 38 | } |
| 39 | |
| 40 | contains(pos, end) { |
| 41 | if (!end) end = pos |
| 42 | for (let i = 0; i < this.ranges.length; i++) { |
| 43 | let range = this.ranges[i] |
| 44 | if (cmp(end, range.from()) >= 0 && cmp(pos, range.to()) <= 0) |
| 45 | return i |
| 46 | } |
| 47 | return -1 |
| 48 | } |
| 49 | } |
| 50 | |
| 51 | export class Range { |
no test coverage detected