Update LKG

This commit is contained in:
TypeScript Bot
2025-01-08 00:16:22 +00:00
parent 8bc02048a2
commit a5e123d9e0
2 changed files with 2 additions and 2 deletions

View File

@@ -50327,7 +50327,7 @@ function createTypeChecker(host) {
return true;
}
if (requiresAddingUndefined && annotationType) {
annotationType = getOptionalType(annotationType, !isParameter(node));
annotationType = addOptionality(annotationType, !isParameter(node));
}
return !!annotationType && typeNodeIsEquivalentToType(node, type, annotationType) && existingTypeNodeIsNotReferenceOrIsReferenceWithCompatibleTypeArgumentCount(existing, type);
}

View File

@@ -54930,7 +54930,7 @@ function createTypeChecker(host) {
return true;
}
if (requiresAddingUndefined && annotationType) {
annotationType = getOptionalType(annotationType, !isParameter(node));
annotationType = addOptionality(annotationType, !isParameter(node));
}
return !!annotationType && typeNodeIsEquivalentToType(node, type, annotationType) && existingTypeNodeIsNotReferenceOrIsReferenceWithCompatibleTypeArgumentCount(existing, type);
}