MCPcopy Create free account
hub / github.com/estools/esquery / peg$parse_

Function peg$parse_

parser.js:473–507  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

471 }
472
473 function peg$parse_() {
474 var s0, s1;
475
476 var key = peg$currPos * 32 + 1,
477 cached = peg$resultsCache[key];
478
479 if (cached) {
480 peg$currPos = cached.nextPos;
481
482 return cached.result;
483 }
484
485 s0 = [];
486 if (input.charCodeAt(peg$currPos) === 32) {
487 s1 = peg$c2;
488 peg$currPos++;
489 } else {
490 s1 = peg$FAILED;
491 if (peg$silentFails === 0) { peg$fail(peg$c3); }
492 }
493 while (s1 !== peg$FAILED) {
494 s0.push(s1);
495 if (input.charCodeAt(peg$currPos) === 32) {
496 s1 = peg$c2;
497 peg$currPos++;
498 } else {
499 s1 = peg$FAILED;
500 if (peg$silentFails === 0) { peg$fail(peg$c3); }
501 }
502 }
503
504 peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
505
506 return s0;
507 }
508
509 function peg$parseidentifierName() {
510 var s0, s1, s2;

Callers 12

peg$parsestartFunction · 0.85
peg$parsebinaryOpFunction · 0.85
peg$parsehasSelectorsFunction · 0.85
peg$parseselectorsFunction · 0.85
peg$parseattrFunction · 0.85
peg$parseattrValueFunction · 0.85
peg$parsetypeFunction · 0.85
peg$parsenegationFunction · 0.85
peg$parsematchesFunction · 0.85
peg$parsehasFunction · 0.85
peg$parsenthChildFunction · 0.85
peg$parsenthLastChildFunction · 0.85

Calls 1

peg$failFunction · 0.85

Tested by

no test coverage detected