-
Notifications
You must be signed in to change notification settings - Fork 49.7k
Description
React version:
19.2.0Steps To Reproduce
-
Go to
[scheduleUpdateOnFiber](https://github.com/facebook/react/blob/main/packages/react-reconciler/src/ReactFiberWorkLoop.js)function inreact-reconciler -
Find this line:
if ((executionContext & RenderContext) !== NoLanes && root === workInProgressRoot)
-
Notice that
executionContextis a set of context flags (bitmask), whileNoLanesrefers to lane priorities and is not used in context checks anywhere else
Link to code example
No runtime code needed — this is a logic-level mismatch in the internal source file.
Relevant file:
packages/react-reconciler/src/ReactFiberWorkLoop.js
❌ The current behavior
The line:
(executionContext & RenderContext) !== NoLanesuses NoLanes in a bitmask comparison with executionContext, which is inconsistent with surrounding usages that compare with NoContext.
NoLanes is defined in the Lane system and is intended for scheduling lanes, not execution contexts.
✅ The expected behavior
This line should likely be:
(executionContext & RenderContext) !== NoContextThis matches similar checks throughout the codebase and would avoid incorrect context evaluation.