Skip to content

Commit 93cf637

Browse files
committed
fix: disable named evaluation for parenthesized rhs
1 parent 8472461 commit 93cf637

File tree

1 file changed

+1
-1
lines changed
  • packages/babel-plugin-proposal-explicit-resource-management/src

1 file changed

+1
-1
lines changed

packages/babel-plugin-proposal-explicit-resource-management/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ const enum USING_KIND {
1313
function isAnonymousFunctionDefinition(
1414
node: t.Node,
1515
): node is t.ClassExpression {
16-
return t.isClassExpression(node) && !node.id;
16+
return t.isClassExpression(node) && !node.id && !node.extra?.parenthesized;
1717
}
1818

1919
function emitSetFunctionNameCall(

0 commit comments

Comments
 (0)