(count: number)
| 92 | } |
| 93 | |
| 94 | const hex = (count: number) => { |
| 95 | let value = 0 |
| 96 | for (const end = i + count; i < end; i++) { |
| 97 | const code = text.charCodeAt(i) |
| 98 | const lower = code | 0x20 |
| 99 | if (isDigit(code)) value = value * 16 + code - 0x30 |
| 100 | else if (lower >= 0x61 && lower <= 0x66) value = value * 16 + lower - 0x57 |
| 101 | else fail(i) |
| 102 | } |
| 103 | return String.fromCharCode(value) |
| 104 | } |
| 105 | |
| 106 | const number = () => { |
| 107 | if (!json5) { |
no test coverage detected