diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index ca96f9b2ae7..4e70cd4e1c5 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -33171,12 +33171,7 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker { const candidates = candidatesOutArray || []; // reorderCandidates fills up the candidates array directly reorderCandidates(signatures, candidates, callChainFlags); - if (!candidates.length) { - if (reportErrors) { - diagnostics.add(getDiagnosticForCallNode(node, Diagnostics.Call_target_does_not_contain_any_signatures)); - } - return resolveErrorCall(node); - } + Debug.assert(candidates.length, "Revert #54442 and add a testcase with whatever triggered this"); const args = getEffectiveCallArguments(node); diff --git a/src/compiler/diagnosticMessages.json b/src/compiler/diagnosticMessages.json index aaad87e0fd8..56b273d5c2e 100644 --- a/src/compiler/diagnosticMessages.json +++ b/src/compiler/diagnosticMessages.json @@ -1860,10 +1860,6 @@ "category": "Error", "code": 2345 }, - "Call target does not contain any signatures.": { - "category": "Error", - "code": 2346 - }, "Untyped function calls may not accept type arguments.": { "category": "Error", "code": 2347