(i, u)
| 21009 | } |
| 21010 | let C = {} |
| 21011 | function processLexeme(i, u) { |
| 21012 | const w = u && u[0] |
| 21013 | if (((Y += i), null == w)) return (processBuffer(), 0) |
| 21014 | if ('begin' === C.type && 'end' === u.type && C.index === u.index && '' === w) { |
| 21015 | if (((Y += o.slice(u.index, u.index + 1)), !_)) { |
| 21016 | const o = new Error('0 width match regex') |
| 21017 | throw ((o.languageName = s), (o.badRule = C.rule), o) |
| 21018 | } |
| 21019 | return 1 |
| 21020 | } |
| 21021 | if (((C = u), 'begin' === u.type)) return doBeginMatch(u) |
| 21022 | if ('illegal' === u.type && !a) { |
| 21023 | const s = new Error( |
| 21024 | 'Illegal lexeme "' + w + '" for mode "' + (U.className || '<unnamed>') + '"' |
| 21025 | ) |
| 21026 | throw ((s.mode = U), s) |
| 21027 | } |
| 21028 | if ('end' === u.type) { |
| 21029 | const s = doEndMatch(u) |
| 21030 | if (s !== we) return s |
| 21031 | } |
| 21032 | if ('illegal' === u.type && '' === w) return 1 |
| 21033 | if (ie > 1e5 && ie > 3 * u.index) { |
| 21034 | throw new Error('potential infinite loop, way more iterations than matches') |
| 21035 | } |
| 21036 | return ((Y += w), w.length) |
| 21037 | } |
| 21038 | const L = getLanguage(s) |
| 21039 | if (!L) throw (error(x.replace('{}', s)), new Error('Unknown language: "' + s + '"')) |
| 21040 | const B = compileLanguage(L, { plugins: u }) |
no test coverage detected