Skip to content

Commit ca9b6a7

Browse files
committed
[compiler] Fix visitors to emit the correct kind
Our passes aren't sequenced such that we could observe this bug, but this retains the proper terminal kind for pruned-scopes in mapTerminalSuccessors. ghstack-source-id: 1a03b40 Pull Request resolved: #29884
1 parent d9a5b63 commit ca9b6a7

File tree

1 file changed

+1
-1
lines changed
  • compiler/packages/babel-plugin-react-compiler/src/HIR

1 file changed

+1
-1
lines changed

compiler/packages/babel-plugin-react-compiler/src/HIR/visitors.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -856,7 +856,7 @@ export function mapTerminalSuccessors(
856856
const block = fn(terminal.block);
857857
const fallthrough = fn(terminal.fallthrough);
858858
return {
859-
kind: "scope",
859+
kind: terminal.kind,
860860
scope: terminal.scope,
861861
block,
862862
fallthrough,

0 commit comments

Comments
 (0)