(returnFiber, childToDelete)
| 8272 | // live outside of this function. |
| 8273 | function ChildReconciler(shouldTrackSideEffects) { |
| 8274 | function deleteChild(returnFiber, childToDelete) { |
| 8275 | if (!shouldTrackSideEffects) { |
| 8276 | // Noop. |
| 8277 | return; |
| 8278 | } |
| 8279 | // Deletions are added in reversed order so we add it to the front. |
| 8280 | // At this point, the return fiber's effect list is empty except for |
| 8281 | // deletions, so we can just append the deletion to the list. The remaining |
| 8282 | // effects aren't added until the complete phase. Once we implement |
| 8283 | // resuming, this may not be true. |
| 8284 | var last = returnFiber.lastEffect; |
| 8285 | if (last !== null) { |
| 8286 | last.nextEffect = childToDelete; |
| 8287 | returnFiber.lastEffect = childToDelete; |
| 8288 | } else { |
| 8289 | returnFiber.firstEffect = returnFiber.lastEffect = childToDelete; |
| 8290 | } |
| 8291 | childToDelete.nextEffect = null; |
| 8292 | childToDelete.effectTag = Deletion; |
| 8293 | } |
| 8294 | |
| 8295 | function deleteRemainingChildren(returnFiber, currentFirstChild) { |
| 8296 | if (!shouldTrackSideEffects) { |
no outgoing calls
no test coverage detected