dillon1000/react

Commit

[rhir] Preserve block labels + target blockIds for break/continue terminals

RFC: we can either retain break/continue target ids (instead of pruning them in 
`buildReactiveFunction`) or re-implement the same logic in `propagateScopeDeps` 
(ignore implicit breaks; match unlabeled break / continues to their closest loop 
/ while parent terminal). 

If we go ahead with this approach, I'll clean up this PR (add relevant types and 
comments)
Browse files
Changed paths7 files
First-parent comparison
M compiler/packages/babel-plugin-react-forget/src/HIR/HIR.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/ReactiveScopes/BuildReactiveBlocks.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/ReactiveScopes/BuildReactiveFunction.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/ReactiveScopes/CodegenReactiveFunction.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/ReactiveScopes/PrintReactiveFunction.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/ReactiveScopes/PropagateEarlyReturns.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/ReactiveScopes/PruneUnusedLabels.ts Modified
Patch

Files changed

Rendering syntax-highlighted changes…