()
| 2611 | } |
| 2612 | |
| 2613 | function peg$parseclass() { |
| 2614 | var s0, s1, s2; |
| 2615 | |
| 2616 | var key = peg$currPos * 32 + 31, |
| 2617 | cached = peg$resultsCache[key]; |
| 2618 | |
| 2619 | if (cached) { |
| 2620 | peg$currPos = cached.nextPos; |
| 2621 | |
| 2622 | return cached.result; |
| 2623 | } |
| 2624 | |
| 2625 | s0 = peg$currPos; |
| 2626 | if (input.charCodeAt(peg$currPos) === 58) { |
| 2627 | s1 = peg$c101; |
| 2628 | peg$currPos++; |
| 2629 | } else { |
| 2630 | s1 = peg$FAILED; |
| 2631 | if (peg$silentFails === 0) { peg$fail(peg$c102); } |
| 2632 | } |
| 2633 | if (s1 !== peg$FAILED) { |
| 2634 | s2 = peg$parseidentifierName(); |
| 2635 | if (s2 !== peg$FAILED) { |
| 2636 | peg$savedPos = s0; |
| 2637 | s1 = peg$c103(s2); |
| 2638 | s0 = s1; |
| 2639 | } else { |
| 2640 | peg$currPos = s0; |
| 2641 | s0 = peg$FAILED; |
| 2642 | } |
| 2643 | } else { |
| 2644 | peg$currPos = s0; |
| 2645 | s0 = peg$FAILED; |
| 2646 | } |
| 2647 | |
| 2648 | peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 }; |
| 2649 | |
| 2650 | return s0; |
| 2651 | } |
| 2652 | |
| 2653 | |
| 2654 | function nth(n) { return { type: 'nth-child', index: { type: 'literal', value: n } }; } |
no test coverage detected