Skip to content

[compiler] Handle sequential optionals#35673

Open
josephsavona wants to merge 1 commit intofacebook:mainfrom
josephsavona:nested-sequential-optionals-rebased
Open

[compiler] Handle sequential optionals#35673
josephsavona wants to merge 1 commit intofacebook:mainfrom
josephsavona:nested-sequential-optionals-rebased

Conversation

@josephsavona
Copy link
Member

The previous PR (#35606) handled maybe-throw terminals within value blocks, and the changes there also made BuildReactiveFunction able to handle sequential optionals. However, CollectOptionalChainDependencies doesn't yet handle sequential value blocks, like foo(a?.b, b?.c) ?? {}. This PR fixes the remaining case, which means we should no longer have arbitrary limitations around value blocks.

@josephsavona josephsavona requested a review from mofeiZ February 2, 2026 17:35
@meta-cla meta-cla bot added the CLA Signed label Feb 2, 2026
@github-actions github-actions bot added the React Core Team Opened by a member of the React Core Team label Feb 2, 2026
The previous PR (facebook#35606) handled maybe-throw terminals within value blocks, and the changes there also made BuildReactiveFunction able to handle sequential optionals. However, CollectOptionalChainDependencies doesn't yet handle sequential value blocks, like `foo(a?.b, b?.c) ?? {}`. This PR fixes the remaining case, which means we should no longer have arbitrary limitations around value blocks.
@josephsavona josephsavona force-pushed the nested-sequential-optionals-rebased branch from 85f6336 to 1885025 Compare February 2, 2026 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed React Core Team Opened by a member of the React Core Team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant