dillon1000/react
Commit
Browse files Fix destructuring with mixed local/scope declarations
Fixes T176436488. The logic for rewriting Destructure instructions was correct, but the visitor implementation was accidentally dropping subsequent Destructure instructions within a block after encountering one that needed a rewrite. Switching to use the transform infra (added after this pass was written) fixes it.
Changed paths5 files
First-parent comparisoncompiler/packages/babel-plugin-react-forget/src/ReactiveScopes/ExtractScopeDeclarationsFromDestructuring.ts ModifiedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/sequential-destructuring-assignment-to-scope-declarations.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/sequential-destructuring-assignment-to-scope-declarations.js AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/sequential-destructuring-both-mixed-local-and-scope-declaration.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/sequential-destructuring-both-mixed-local-and-scope-declaration.js AddedPatch
Files changed
Rendering syntax-highlighted changes…