mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
75c7fdcbd0
There was one missing piece to the optimization from the previous PR: Array#map can return an alias to the receiver in its output, which means that mutations of the result have to be treated as mutations of the receiver. This means we need to use a Capture effect on the receiver. If that doesn't get downgraded to a Read bc the value was immutable, we then also need to make the lvalue effect a Store (so that InferMutableRanges actually looks at it for aliasing).