MCPcopy Create free account
hub / github.com/codemix/graph / peg$parseYIELD

Function peg$parseYIELD

packages/graph/src/grammar.js:16322–16357  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

16320 }
16321
16322 function peg$parseYIELD() {
16323 let s0, s1, s2, s3;
16324
16325 s0 = peg$currPos;
16326 s1 = input.substr(peg$currPos, 5);
16327 if (s1.toLowerCase() === peg$c102) {
16328 peg$currPos += (5);
16329 } else {
16330 s1 = peg$FAILED;
16331 if (peg$silentFails === 0) { peg$fail(peg$e107); }
16332 }
16333 if (s1 !== peg$FAILED) {
16334 s2 = peg$currPos;
16335 peg$silentFails++;
16336 s3 = peg$parseIdentifierPart();
16337 peg$silentFails--;
16338 if (s3 === peg$FAILED) {
16339 s2 = undefined;
16340 } else {
16341 peg$currPos = s2;
16342 s2 = peg$FAILED;
16343 }
16344 if (s2 !== peg$FAILED) {
16345 s1 = [s1, s2];
16346 s0 = s1;
16347 } else {
16348 peg$currPos = s0;
16349 s0 = peg$FAILED;
16350 }
16351 } else {
16352 peg$currPos = s0;
16353 s0 = peg$FAILED;
16354 }
16355
16356 return s0;
16357 }
16358
16359 function peg$parseLiteral() {
16360 let s0;

Callers 2

peg$parseYieldClauseFunction · 0.85
peg$parseKeywordFunction · 0.85

Calls 2

peg$failFunction · 0.85
peg$parseIdentifierPartFunction · 0.85

Tested by

no test coverage detected