(workInProgress)
| 12544 | } |
| 12545 | |
| 12546 | function performUnitOfWork(workInProgress) { |
| 12547 | // The current, flushed, state of this fiber is the alternate. |
| 12548 | // Ideally nothing should rely on this, but relying on it here |
| 12549 | // means that we don't need an additional field on the work in |
| 12550 | // progress. |
| 12551 | var current = workInProgress.alternate; |
| 12552 | |
| 12553 | // See if beginning this work spawns more work. |
| 12554 | startWorkTimer(workInProgress); |
| 12555 | { |
| 12556 | ReactDebugCurrentFiber.setCurrentFiber(workInProgress); |
| 12557 | } |
| 12558 | |
| 12559 | if (true && replayFailedUnitOfWorkWithInvokeGuardedCallback) { |
| 12560 | stashedWorkInProgressProperties = _assign({}, workInProgress); |
| 12561 | } |
| 12562 | var next = beginWork(current, workInProgress, nextRenderExpirationTime); |
| 12563 | |
| 12564 | { |
| 12565 | ReactDebugCurrentFiber.resetCurrentFiber(); |
| 12566 | } |
| 12567 | if (true && ReactFiberInstrumentation_1.debugTool) { |
| 12568 | ReactFiberInstrumentation_1.debugTool.onBeginWork(workInProgress); |
| 12569 | } |
| 12570 | |
| 12571 | if (next === null) { |
| 12572 | // If this doesn't spawn new work, complete the current work. |
| 12573 | next = completeUnitOfWork(workInProgress); |
| 12574 | } |
| 12575 | |
| 12576 | ReactCurrentOwner.current = null; |
| 12577 | |
| 12578 | return next; |
| 12579 | } |
| 12580 | |
| 12581 | function workLoop(isAsync) { |
| 12582 | if (!isAsync) { |
no test coverage detected