Skip to content

Commit 5dccbb7

Browse files
Remove "unnecessary" type assertions.
1 parent 9d42982 commit 5dccbb7

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/compiler/checker.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30102,8 +30102,8 @@ namespace ts {
3010230102
if (node.kind === SyntaxKind.VariableDeclaration || node.kind === SyntaxKind.BindingElement) {
3010330103
checkVarDeclaredNamesNotShadowed(node);
3010430104
}
30105-
checkCollisionWithRequireExportsInGeneratedCode(node, <Identifier>node.name);
30106-
checkCollisionWithGlobalPromiseInGeneratedCode(node, <Identifier>node.name);
30105+
checkCollisionWithRequireExportsInGeneratedCode(node, node.name);
30106+
checkCollisionWithGlobalPromiseInGeneratedCode(node, node.name);
3010730107
}
3010830108
}
3010930109

@@ -35268,10 +35268,10 @@ namespace ts {
3526835268
node.kind === SyntaxKind.FunctionExpression ||
3526935269
node.kind === SyntaxKind.MethodDeclaration);
3527035270
if (node.flags & NodeFlags.Ambient) {
35271-
return grammarErrorOnNode(node.asteriskToken!, Diagnostics.Generators_are_not_allowed_in_an_ambient_context);
35271+
return grammarErrorOnNode(node.asteriskToken, Diagnostics.Generators_are_not_allowed_in_an_ambient_context);
3527235272
}
3527335273
if (!node.body) {
35274-
return grammarErrorOnNode(node.asteriskToken!, Diagnostics.An_overload_signature_cannot_be_declared_as_a_generator);
35274+
return grammarErrorOnNode(node.asteriskToken, Diagnostics.An_overload_signature_cannot_be_declared_as_a_generator);
3527535275
}
3527635276
}
3527735277
}

0 commit comments

Comments
 (0)