(input, start, end, lit)
| 318 | * @returns {boolean} true if the range equals `lit` ignoring ASCII case |
| 319 | */ |
| 320 | const rangeEqualsLower = (input, start, end, lit) => { |
| 321 | if (end - start !== lit.length) return false; |
| 322 | for (let i = 0; i < lit.length; i++) { |
| 323 | let c = input.charCodeAt(start + i); |
| 324 | if (c >= 0x41 && c <= 0x5a) c += 0x20; |
| 325 | if (c !== lit.charCodeAt(i)) return false; |
| 326 | } |
| 327 | return true; |
| 328 | }; |
| 329 | |
| 330 | /** |
| 331 | * Content mode for the just-opened tag whose name spans `input[start..end)`, |
no outgoing calls
no test coverage detected