Skip to content

Commit 142824b

Browse files
author
Andy Hanson
committed
Remove assertion
1 parent 52d830f commit 142824b

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/compiler/utilities.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4300,9 +4300,7 @@ namespace ts {
43004300

43014301
/** @internal */
43024302
export function isNamedDeclaration(node: Node): node is NamedDeclaration & { name: DeclarationName } {
4303-
const name = (node as NamedDeclaration).name;
4304-
Debug.assert(!name || isDeclaration(node) && node.name === name, "A 'name' property should always be a DeclarationName.");
4305-
return !!name;
4303+
return !!(node as NamedDeclaration).name; // A 'name' property should always be a DeclarationName.
43064304
}
43074305

43084306
export function getNameOfDeclaration(declaration: Declaration | Expression): DeclarationName | undefined {

0 commit comments

Comments
 (0)