(returnFiber, childToDelete)
| 9049 | // live outside of this function. |
| 9050 | function ChildReconciler(shouldTrackSideEffects) { |
| 9051 | function deleteChild(returnFiber, childToDelete) { |
| 9052 | if (!shouldTrackSideEffects) { |
| 9053 | // Noop. |
| 9054 | return; |
| 9055 | } |
| 9056 | // Deletions are added in reversed order so we add it to the front. |
| 9057 | // At this point, the return fiber's effect list is empty except for |
| 9058 | // deletions, so we can just append the deletion to the list. The remaining |
| 9059 | // effects aren't added until the complete phase. Once we implement |
| 9060 | // resuming, this may not be true. |
| 9061 | var last = returnFiber.lastEffect; |
| 9062 | if (last !== null) { |
| 9063 | last.nextEffect = childToDelete; |
| 9064 | returnFiber.lastEffect = childToDelete; |
| 9065 | } else { |
| 9066 | returnFiber.firstEffect = returnFiber.lastEffect = childToDelete; |
| 9067 | } |
| 9068 | childToDelete.nextEffect = null; |
| 9069 | childToDelete.effectTag = Deletion; |
| 9070 | } |
| 9071 | |
| 9072 | function deleteRemainingChildren(returnFiber, currentFirstChild) { |
| 9073 | if (!shouldTrackSideEffects) { |
no outgoing calls
no test coverage detected