()
| 12646 | }; |
| 12647 | |
| 12648 | var ReactFiberStack = function () { |
| 12649 | var valueStack = []; |
| 12650 | |
| 12651 | var fiberStack = void 0; |
| 12652 | |
| 12653 | { |
| 12654 | fiberStack = []; |
| 12655 | } |
| 12656 | |
| 12657 | var index = -1; |
| 12658 | |
| 12659 | function createCursor(defaultValue) { |
| 12660 | return { |
| 12661 | current: defaultValue |
| 12662 | }; |
| 12663 | } |
| 12664 | |
| 12665 | function isEmpty() { |
| 12666 | return index === -1; |
| 12667 | } |
| 12668 | |
| 12669 | function pop(cursor, fiber) { |
| 12670 | if (index < 0) { |
| 12671 | { |
| 12672 | warning(false, 'Unexpected pop.'); |
| 12673 | } |
| 12674 | return; |
| 12675 | } |
| 12676 | |
| 12677 | { |
| 12678 | if (fiber !== fiberStack[index]) { |
| 12679 | warning(false, 'Unexpected Fiber popped.'); |
| 12680 | } |
| 12681 | } |
| 12682 | |
| 12683 | cursor.current = valueStack[index]; |
| 12684 | |
| 12685 | valueStack[index] = null; |
| 12686 | |
| 12687 | { |
| 12688 | fiberStack[index] = null; |
| 12689 | } |
| 12690 | |
| 12691 | index--; |
| 12692 | } |
| 12693 | |
| 12694 | function push(cursor, value, fiber) { |
| 12695 | index++; |
| 12696 | |
| 12697 | valueStack[index] = cursor.current; |
| 12698 | |
| 12699 | { |
| 12700 | fiberStack[index] = fiber; |
| 12701 | } |
| 12702 | |
| 12703 | cursor.current = value; |
| 12704 | } |
| 12705 |
no outgoing calls
no test coverage detected