MCPcopy Create free account
hub / github.com/codemix/htmling / peg$parseNumber

Function peg$parseNumber

lib/parser.js:4571–4643  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4569 }
4570
4571 function peg$parseNumber() {
4572 var s0, s1, s2, s3, s4, s5, s6, s7;
4573
4574 s0 = peg$currPos;
4575 s1 = peg$currPos;
4576 s2 = peg$currPos;
4577 s3 = [];
4578 s4 = peg$parseDecimalDigit();
4579 if (s4 !== peg$FAILED) {
4580 while (s4 !== peg$FAILED) {
4581 s3.push(s4);
4582 s4 = peg$parseDecimalDigit();
4583 }
4584 } else {
4585 s3 = peg$c3;
4586 }
4587 if (s3 !== peg$FAILED) {
4588 s4 = peg$currPos;
4589 if (input.charCodeAt(peg$currPos) === 46) {
4590 s5 = peg$c162;
4591 peg$currPos++;
4592 } else {
4593 s5 = peg$FAILED;
4594 if (peg$silentFails === 0) { peg$fail(peg$c163); }
4595 }
4596 if (s5 !== peg$FAILED) {
4597 s6 = [];
4598 s7 = peg$parseDecimalDigit();
4599 if (s7 !== peg$FAILED) {
4600 while (s7 !== peg$FAILED) {
4601 s6.push(s7);
4602 s7 = peg$parseDecimalDigit();
4603 }
4604 } else {
4605 s6 = peg$c3;
4606 }
4607 if (s6 !== peg$FAILED) {
4608 s5 = [s5, s6];
4609 s4 = s5;
4610 } else {
4611 peg$currPos = s4;
4612 s4 = peg$c3;
4613 }
4614 } else {
4615 peg$currPos = s4;
4616 s4 = peg$c3;
4617 }
4618 if (s4 === peg$FAILED) {
4619 s4 = peg$c0;
4620 }
4621 if (s4 !== peg$FAILED) {
4622 s3 = [s3, s4];
4623 s2 = s3;
4624 } else {
4625 peg$currPos = s2;
4626 s2 = peg$c3;
4627 }
4628 } else {

Callers 1

peg$parseLiteralFunction · 0.85

Calls 3

peg$parseDecimalDigitFunction · 0.85
peg$failFunction · 0.85
peg$c164Function · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…