Skip to content

Commit 28da1c5

Browse files
committed
Reinstate isCatchClauseVariableDeclaration
1 parent 1466ba5 commit 28da1c5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/compiler/utilities.ts

+5
Original file line numberDiff line numberDiff line change
@@ -10346,6 +10346,11 @@ export function isInfinityOrNaNString(name: string | __String): boolean {
1034610346
return name === "Infinity" || name === "-Infinity" || name === "NaN";
1034710347
}
1034810348

10349+
/** @internal */
10350+
export function isCatchClauseVariableDeclaration(node: Node) {
10351+
return node.kind === SyntaxKind.VariableDeclaration && node.parent.kind === SyntaxKind.CatchClause;
10352+
}
10353+
1034910354
/** @internal */
1035010355
export function isFunctionExpressionOrArrowFunction(node: Node): node is FunctionExpression | ArrowFunction {
1035110356
return node.kind === SyntaxKind.FunctionExpression || node.kind === SyntaxKind.ArrowFunction;

0 commit comments

Comments
 (0)