(returnFiber, childToDelete)
| 8144 | // live outside of this function. |
| 8145 | function ChildReconciler(shouldTrackSideEffects) { |
| 8146 | function deleteChild(returnFiber, childToDelete) { |
| 8147 | if (!shouldTrackSideEffects) { |
| 8148 | // Noop. |
| 8149 | return; |
| 8150 | } |
| 8151 | // Deletions are added in reversed order so we add it to the front. |
| 8152 | // At this point, the return fiber's effect list is empty except for |
| 8153 | // deletions, so we can just append the deletion to the list. The remaining |
| 8154 | // effects aren't added until the complete phase. Once we implement |
| 8155 | // resuming, this may not be true. |
| 8156 | var last = returnFiber.lastEffect; |
| 8157 | if (last !== null) { |
| 8158 | last.nextEffect = childToDelete; |
| 8159 | returnFiber.lastEffect = childToDelete; |
| 8160 | } else { |
| 8161 | returnFiber.firstEffect = returnFiber.lastEffect = childToDelete; |
| 8162 | } |
| 8163 | childToDelete.nextEffect = null; |
| 8164 | childToDelete.effectTag = Deletion; |
| 8165 | } |
| 8166 | |
| 8167 | function deleteRemainingChildren(returnFiber, currentFirstChild) { |
| 8168 | if (!shouldTrackSideEffects) { |
no outgoing calls
no test coverage detected