mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Fixed crash related to creating file diagnostics outside of the source file range in checkPotentialUncheckedRenamedBindingElementsInTypes (#59428)
This commit is contained in:
@@ -43552,7 +43552,7 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
|
||||
// entire parameter does not have type annotation, suggest adding an annotation
|
||||
addRelatedInfo(
|
||||
diagnostic,
|
||||
createFileDiagnostic(getSourceFileOfNode(wrappingDeclaration), wrappingDeclaration.end, 1, Diagnostics.We_can_only_write_a_type_for_0_by_adding_a_type_for_the_entire_parameter_here, declarationNameToString(node.propertyName)),
|
||||
createFileDiagnostic(getSourceFileOfNode(wrappingDeclaration), wrappingDeclaration.end, 0, Diagnostics.We_can_only_write_a_type_for_0_by_adding_a_type_for_the_entire_parameter_here, declarationNameToString(node.propertyName)),
|
||||
);
|
||||
}
|
||||
diagnostics.add(diagnostic);
|
||||
|
||||
Reference in New Issue
Block a user