diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index dde8033d1e9..12f6e3e579a 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -15336,7 +15336,7 @@ namespace ts { } } - function resolveCall(node: CallLikeExpression, signatures: Signature[], candidatesOutArray: Signature[], headMessage?: DiagnosticMessage): Signature { + function resolveCall(node: CallLikeExpression, signatures: Signature[], candidatesOutArray: Signature[], fallbackError?: DiagnosticMessage): Signature { const isTaggedTemplate = node.kind === SyntaxKind.TaggedTemplateExpression; const isDecorator = node.kind === SyntaxKind.Decorator; const isJsxOpeningOrSelfClosingElement = isJsxOpeningLikeElement(node); @@ -15371,7 +15371,7 @@ namespace ts { // reorderCandidates fills up the candidates array directly reorderCandidates(signatures, candidates); if (!candidates.length) { - reportError(Diagnostics.Supplied_parameters_do_not_match_any_signature_of_call_target); + diagnostics.add(createDiagnosticForNode(node, Diagnostics.Call_target_does_not_contain_any_signatures)); return resolveErrorCall(node); } @@ -15479,7 +15479,7 @@ namespace ts { else if (candidateForTypeArgumentError) { if (!isTaggedTemplate && !isDecorator && typeArguments) { const typeArguments = (node).typeArguments; - checkTypeArguments(candidateForTypeArgumentError, typeArguments, map(typeArguments, getTypeFromTypeNode), /*reportErrors*/ true, headMessage); + checkTypeArguments(candidateForTypeArgumentError, typeArguments, map(typeArguments, getTypeFromTypeNode), /*reportErrors*/ true, fallbackError); } else { Debug.assert(resultOfFailedInference.failedTypeParameterIndex >= 0); @@ -15490,15 +15490,44 @@ namespace ts { Diagnostics.The_type_argument_for_type_parameter_0_cannot_be_inferred_from_the_usage_Consider_specifying_the_type_arguments_explicitly, typeToString(failedTypeParameter)); - if (headMessage) { - diagnosticChainHead = chainDiagnosticMessages(diagnosticChainHead, headMessage); + if (fallbackError) { + diagnosticChainHead = chainDiagnosticMessages(diagnosticChainHead, fallbackError); } reportNoCommonSupertypeError(inferenceCandidates, (node).tagName || (node).expression || (node).tag, diagnosticChainHead); } } - else { - reportError(Diagnostics.Supplied_parameters_do_not_match_any_signature_of_call_target); + else if (typeArguments && every(signatures, sig => length(sig.typeParameters) !== typeArguments.length)) { + let min = Number.POSITIVE_INFINITY; + let max = Number.NEGATIVE_INFINITY; + for (const sig of signatures) { + min = Math.min(min, getMinTypeArgumentCount(sig.typeParameters)); + max = Math.max(max, length(sig.typeParameters)); + } + const paramCount = min < max ? `${min}-${max}` : min; + diagnostics.add(createDiagnosticForNode(node, Diagnostics.Expected_0_type_arguments_but_got_1, paramCount, typeArguments.length)); + } + else if (args) { + let min = Number.POSITIVE_INFINITY; + let max = Number.NEGATIVE_INFINITY; + for (const sig of signatures) { + min = Math.min(min, sig.minArgumentCount); + max = Math.max(max, sig.parameters.length); + } + const hasRestParameter = some(signatures, sig => sig.hasRestParameter); + const hasSpreadArgument = getSpreadArgumentIndex(args) > -1; + const paramCount = hasRestParameter ? min : + min < max ? `${min}-${max}` : + min; + const argCount = args.length - (hasSpreadArgument ? 1 : 0); + const error = hasRestParameter && hasSpreadArgument ? Diagnostics.Expected_at_least_0_arguments_but_got_a_minimum_of_1 : + hasRestParameter ? Diagnostics.Expected_at_least_0_arguments_but_got_1 : + hasSpreadArgument ? Diagnostics.Expected_0_arguments_but_got_a_minimum_of_1 : + Diagnostics.Expected_0_arguments_but_got_1; + diagnostics.add(createDiagnosticForNode(node, error, paramCount, argCount)); + } + else if (fallbackError) { + diagnostics.add(createDiagnosticForNode(node, fallbackError)); } // No signature was applicable. We have already reported the errors for the invalid signature. @@ -15519,16 +15548,6 @@ namespace ts { return resolveErrorCall(node); - function reportError(message: DiagnosticMessage, arg0?: string, arg1?: string, arg2?: string): void { - let errorInfo: DiagnosticMessageChain; - errorInfo = chainDiagnosticMessages(errorInfo, message, arg0, arg1, arg2); - if (headMessage) { - errorInfo = chainDiagnosticMessages(errorInfo, headMessage); - } - - diagnostics.add(createDiagnosticForNodeFromMessageChain(node, errorInfo)); - } - function chooseOverload(candidates: Signature[], relation: Map, signatureHelpTrailingComma = false) { for (const originalCandidate of candidates) { if (!hasCorrectArity(node, args, originalCandidate, signatureHelpTrailingComma)) { diff --git a/src/compiler/diagnosticMessages.json b/src/compiler/diagnosticMessages.json index 36a5303cd58..ffedb45c2e0 100644 --- a/src/compiler/diagnosticMessages.json +++ b/src/compiler/diagnosticMessages.json @@ -1067,7 +1067,7 @@ "category": "Error", "code": 2345 }, - "Supplied parameters do not match any signature of call target.": { + "Call target does not contain any signatures.": { "category": "Error", "code": 2346 }, @@ -1859,6 +1859,26 @@ "category": "Error", "code": 2553 }, + "Expected {0} arguments, but got {1}.": { + "category": "Error", + "code": 2554 + }, + "Expected at least {0} arguments, but got {1}.": { + "category": "Error", + "code": 2555 + }, + "Expected {0} arguments, but got a minimum of {1}.": { + "category": "Error", + "code": 2556 + }, + "Expected at least {0} arguments, but got a minimum of {1}.": { + "category": "Error", + "code": 2557 + }, + "Expected {0} type arguments, but got {1}.": { + "category": "Error", + "code": 2558 + }, "JSX element attributes type '{0}' may not be a union type.": { "category": "Error", "code": 2600 diff --git a/tests/baselines/reference/ES5SymbolProperty5.errors.txt b/tests/baselines/reference/ES5SymbolProperty5.errors.txt index bbfb64b6459..fb3a9aa78d4 100644 --- a/tests/baselines/reference/ES5SymbolProperty5.errors.txt +++ b/tests/baselines/reference/ES5SymbolProperty5.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/Symbols/ES5SymbolProperty5.ts(7,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/Symbols/ES5SymbolProperty5.ts(7,1): error TS2554: Expected 0 arguments, but got 1. ==== tests/cases/conformance/Symbols/ES5SymbolProperty5.ts (1 errors) ==== @@ -10,4 +10,4 @@ tests/cases/conformance/Symbols/ES5SymbolProperty5.ts(7,1): error TS2346: Suppli (new C)[Symbol.iterator](0) // Should error ~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 0 arguments, but got 1. \ No newline at end of file diff --git a/tests/baselines/reference/assigningFromObjectToAnythingElse.errors.txt b/tests/baselines/reference/assigningFromObjectToAnythingElse.errors.txt index d3395c7ebc9..c8fb57e3616 100644 --- a/tests/baselines/reference/assigningFromObjectToAnythingElse.errors.txt +++ b/tests/baselines/reference/assigningFromObjectToAnythingElse.errors.txt @@ -1,8 +1,8 @@ tests/cases/compiler/assigningFromObjectToAnythingElse.ts(3,1): error TS2322: Type 'Object' is not assignable to type 'RegExp'. The 'Object' type is assignable to very few other types. Did you mean to use the 'any' type instead? Property 'exec' is missing in type 'Object'. -tests/cases/compiler/assigningFromObjectToAnythingElse.ts(5,17): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/assigningFromObjectToAnythingElse.ts(6,17): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/assigningFromObjectToAnythingElse.ts(5,17): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/compiler/assigningFromObjectToAnythingElse.ts(6,17): error TS2558: Expected 0 type arguments, but got 1. tests/cases/compiler/assigningFromObjectToAnythingElse.ts(8,5): error TS2322: Type 'Object' is not assignable to type 'Error'. The 'Object' type is assignable to very few other types. Did you mean to use the 'any' type instead? Property 'name' is missing in type 'Object'. @@ -19,10 +19,10 @@ tests/cases/compiler/assigningFromObjectToAnythingElse.ts(8,5): error TS2322: Ty var a: String = Object.create(""); ~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var c: String = Object.create(1); ~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var w: Error = new Object(); ~ diff --git a/tests/baselines/reference/baseCheck.errors.txt b/tests/baselines/reference/baseCheck.errors.txt index 1353d6e1a08..0ae410d4e34 100644 --- a/tests/baselines/reference/baseCheck.errors.txt +++ b/tests/baselines/reference/baseCheck.errors.txt @@ -1,5 +1,5 @@ tests/cases/compiler/baseCheck.ts(9,18): error TS2552: Cannot find name 'loc'. Did you mean 'ELoc'? -tests/cases/compiler/baseCheck.ts(17,53): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/baseCheck.ts(17,53): error TS2554: Expected 2 arguments, but got 1. tests/cases/compiler/baseCheck.ts(17,59): error TS17009: 'super' must be called before accessing 'this' in the constructor of a derived class. tests/cases/compiler/baseCheck.ts(18,62): error TS17009: 'super' must be called before accessing 'this' in the constructor of a derived class. tests/cases/compiler/baseCheck.ts(19,59): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. @@ -30,7 +30,7 @@ tests/cases/compiler/baseCheck.ts(26,9): error TS2304: Cannot find name 'x'. class D extends C { constructor(public z: number) { super(this.z) } } // too few params ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. ~~~~ !!! error TS17009: 'super' must be called before accessing 'this' in the constructor of a derived class. class E extends C { constructor(public z: number) { super(0, this.z) } } diff --git a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES5.errors.txt b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES5.errors.txt index 3efa85d1cc7..77dc618f912 100644 --- a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES5.errors.txt +++ b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES5.errors.txt @@ -1,9 +1,9 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(3,18): error TS2393: Duplicate function implementation. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(5,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(5,9): error TS2554: Expected 0 arguments, but got 1. tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(8,18): error TS2393: Duplicate function implementation. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(10,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(12,5): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(16,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(10,9): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(12,5): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(16,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts (6 errors) ==== @@ -15,7 +15,7 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(16,1): error T foo(); foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } else { function foo() { } // duplicate function @@ -24,14 +24,14 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationES5.ts(16,1): error T foo(); foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. foo(); } foo(10); foo(); // not ok - needs number ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES6.errors.txt b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES6.errors.txt index 5d15278f098..c9a8c67296a 100644 --- a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES6.errors.txt +++ b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationES6.errors.txt @@ -1,9 +1,9 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(3,18): error TS2393: Duplicate function implementation. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(5,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(5,9): error TS2554: Expected 0 arguments, but got 1. tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(8,18): error TS2393: Duplicate function implementation. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(10,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(12,5): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(16,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(10,9): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(12,5): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(16,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts (6 errors) ==== @@ -15,7 +15,7 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(16,1): error T foo(); foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } else { function foo() { } // duplicate @@ -24,14 +24,14 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationES6.ts(16,1): error T foo(); foo(10);// not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. foo(); } foo(10); foo(); // not ok - needs number ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES5.errors.txt b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES5.errors.txt index 36ce2d8c488..fb53f7a8f96 100644 --- a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES5.errors.txt +++ b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES5.errors.txt @@ -1,9 +1,9 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(4,18): error TS1250: Function declarations are not allowed inside blocks in strict mode when targeting 'ES3' or 'ES5'. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(6,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(6,9): error TS2554: Expected 0 arguments, but got 1. tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(9,18): error TS1250: Function declarations are not allowed inside blocks in strict mode when targeting 'ES3' or 'ES5'. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(11,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(14,5): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(17,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(11,9): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(14,5): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(17,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts (6 errors) ==== @@ -16,7 +16,7 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(17,1): e foo(); foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } else { function foo() { } // Error to declare function in block scope @@ -25,14 +25,14 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES5.ts(17,1): e foo(); foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } foo(10); foo(); // not ok - needs number ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. } foo(10); foo(); // not ok - needs number ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES6.errors.txt b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES6.errors.txt index 7b8834c5594..ae2bdcf587f 100644 --- a/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES6.errors.txt +++ b/tests/baselines/reference/blockScopedSameNameFunctionDeclarationStrictES6.errors.txt @@ -1,7 +1,7 @@ -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(6,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(11,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(14,5): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(17,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(6,9): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(11,9): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(14,5): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(17,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts (4 errors) ==== @@ -12,21 +12,21 @@ tests/cases/compiler/blockScopedSameNameFunctionDeclarationStrictES6.ts(17,1): e foo(); foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } else { function foo() { } foo(); foo(10); // not ok ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } foo(10); foo(); // not ok ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. } foo(10); foo(); // not ok - needs number ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.errors.txt b/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.errors.txt index 0e8e8ff9303..6d95b588ebf 100644 --- a/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.errors.txt +++ b/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.errors.txt @@ -1,17 +1,17 @@ -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(5,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(6,11): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(9,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(10,11): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(13,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(14,11): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(21,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(22,11): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(28,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(29,11): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(36,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(37,11): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(43,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(44,11): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(5,10): error TS2558: Expected 2 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(6,11): error TS2558: Expected 2 type arguments, but got 3. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(9,10): error TS2558: Expected 2 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(10,11): error TS2558: Expected 2 type arguments, but got 3. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(13,10): error TS2558: Expected 2 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(14,11): error TS2558: Expected 2 type arguments, but got 3. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(21,10): error TS2558: Expected 2 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(22,11): error TS2558: Expected 2 type arguments, but got 3. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(28,10): error TS2558: Expected 2 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(29,11): error TS2558: Expected 2 type arguments, but got 3. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(36,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(37,11): error TS2558: Expected 0 type arguments, but got 3. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(43,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts(44,11): error TS2558: Expected 0 type arguments, but got 3. ==== tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFunctionWithIncorrectNumberOfTypeArguments.ts (14 errors) ==== @@ -21,26 +21,26 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFuncti function f(x: T, y: U): T { return null; } var r1 = f(1, ''); ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. var r1b = f(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 3. var f2 = (x: T, y: U): T => { return null; } var r2 = f2(1, ''); ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. var r2b = f2(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 3. var f3: { (x: T, y: U): T; } var r3 = f3(1, ''); ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. var r3b = f3(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 3. class C { f(x: T, y: U): T { @@ -49,10 +49,10 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFuncti } var r4 = (new C()).f(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. var r4b = (new C()).f(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 3. interface I { f(x: T, y: U): T; @@ -60,10 +60,10 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFuncti var i: I; var r5 = i.f(1, ''); ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. var r5b = i.f(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 3. class C2 { f(x: T, y: U): T { @@ -72,10 +72,10 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFuncti } var r6 = (new C2()).f(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r6b = (new C2()).f(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 3. interface I2 { f(x: T, y: U): T; @@ -83,7 +83,7 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callGenericFuncti var i2: I2; var r7 = i2.f(1, ''); ~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r7b = i2.f(1, ''); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2558: Expected 0 type arguments, but got 3. \ No newline at end of file diff --git a/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.errors.txt b/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.errors.txt index 6a11751ead3..b014eae0fd8 100644 --- a/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.errors.txt +++ b/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.errors.txt @@ -1,10 +1,10 @@ -tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(5,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(8,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(11,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(18,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(24,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(31,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(37,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(5,9): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(8,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(11,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(18,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(24,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(31,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(37,10): error TS2558: Expected 0 type arguments, but got 1. tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(40,10): error TS2347: Untyped function calls may not accept type arguments. tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFunctionWithTypeArguments.ts(43,10): error TS2347: Untyped function calls may not accept type arguments. @@ -16,17 +16,17 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFun function f(x: number) { return null; } var r = f(1); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var f2 = (x: number) => { return null; } var r2 = f2(1); ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var f3: { (x: number): any; } var r3 = f3(1); ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. class C { f(x: number) { @@ -35,7 +35,7 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFun } var r4 = (new C()).f(1); ~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. interface I { f(x: number): any; @@ -43,7 +43,7 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFun var i: I; var r5 = i.f(1); ~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. class C2 { f(x: number) { @@ -52,7 +52,7 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFun } var r6 = (new C2()).f(1); ~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. interface I2 { f(x: number); @@ -60,7 +60,7 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/callNonGenericFun var i2: I2; var r7 = i2.f(1); ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var a; var r8 = a(); diff --git a/tests/baselines/reference/callOnInstance.errors.txt b/tests/baselines/reference/callOnInstance.errors.txt index 4f80088ab75..5a6bb31ca28 100644 --- a/tests/baselines/reference/callOnInstance.errors.txt +++ b/tests/baselines/reference/callOnInstance.errors.txt @@ -1,7 +1,7 @@ tests/cases/compiler/callOnInstance.ts(1,18): error TS2300: Duplicate identifier 'D'. tests/cases/compiler/callOnInstance.ts(3,15): error TS2300: Duplicate identifier 'D'. -tests/cases/compiler/callOnInstance.ts(7,19): error TS2346: Supplied parameters do not match any signature of call target. tests/cases/compiler/callOnInstance.ts(7,19): error TS2350: Only a void function can be called with the 'new' keyword. +tests/cases/compiler/callOnInstance.ts(7,19): error TS2554: Expected 0 arguments, but got 1. tests/cases/compiler/callOnInstance.ts(10,1): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type 'C' has no compatible call signatures. @@ -18,9 +18,9 @@ tests/cases/compiler/callOnInstance.ts(10,1): error TS2349: Cannot invoke an exp var s2: string = (new D(1))(); ~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. - ~~~~~~~~ !!! error TS2350: Only a void function can be called with the 'new' keyword. + ~~~~~~~~ +!!! error TS2554: Expected 0 arguments, but got 1. declare class C { constructor(value: number); } (new C(1))(); // Error for calling an instance diff --git a/tests/baselines/reference/callWithSpread2.errors.txt b/tests/baselines/reference/callWithSpread2.errors.txt index cfea427a2a7..89617ab6074 100644 --- a/tests/baselines/reference/callWithSpread2.errors.txt +++ b/tests/baselines/reference/callWithSpread2.errors.txt @@ -10,9 +10,9 @@ tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(34,11): err Type 'string' is not assignable to type 'number'. tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(35,11): error TS2345: Argument of type 'string | number' is not assignable to parameter of type 'number'. Type 'string' is not assignable to type 'number'. -tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(36,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(37,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(38,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(36,1): error TS2556: Expected 1-3 arguments, but got a minimum of 0. +tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(37,1): error TS2556: Expected 1-3 arguments, but got a minimum of 0. +tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(38,1): error TS2556: Expected 1-3 arguments, but got a minimum of 0. ==== tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts (9 errors) ==== @@ -71,11 +71,11 @@ tests/cases/conformance/expressions/functionCalls/callWithSpread2.ts(38,1): erro !!! error TS2345: Type 'string' is not assignable to type 'number'. prefix(...ns) // required parameters are required ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2556: Expected 1-3 arguments, but got a minimum of 0. prefix(...mixed) ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2556: Expected 1-3 arguments, but got a minimum of 0. prefix(...tuple) ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2556: Expected 1-3 arguments, but got a minimum of 0. \ No newline at end of file diff --git a/tests/baselines/reference/callWithWrongNumberOfTypeArguments.errors.txt b/tests/baselines/reference/callWithWrongNumberOfTypeArguments.errors.txt index a3776946292..e3fca9dff9c 100644 --- a/tests/baselines/reference/callWithWrongNumberOfTypeArguments.errors.txt +++ b/tests/baselines/reference/callWithWrongNumberOfTypeArguments.errors.txt @@ -1,5 +1,5 @@ -tests/cases/compiler/callWithWrongNumberOfTypeArguments.ts(3,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/callWithWrongNumberOfTypeArguments.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/callWithWrongNumberOfTypeArguments.ts(3,1): error TS2558: Expected 2 type arguments, but got 1. +tests/cases/compiler/callWithWrongNumberOfTypeArguments.ts(5,1): error TS2558: Expected 2 type arguments, but got 3. ==== tests/cases/compiler/callWithWrongNumberOfTypeArguments.ts (2 errors) ==== @@ -7,8 +7,8 @@ tests/cases/compiler/callWithWrongNumberOfTypeArguments.ts(5,1): error TS2346: S f(); ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. f(); f(); ~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2558: Expected 2 type arguments, but got 3. \ No newline at end of file diff --git a/tests/baselines/reference/checkIndexConstraintOfJavascriptClassExpression.errors.txt b/tests/baselines/reference/checkIndexConstraintOfJavascriptClassExpression.errors.txt index d90e6d506ff..b409185a114 100644 --- a/tests/baselines/reference/checkIndexConstraintOfJavascriptClassExpression.errors.txt +++ b/tests/baselines/reference/checkIndexConstraintOfJavascriptClassExpression.errors.txt @@ -1,6 +1,6 @@ tests/cases/compiler/weird.js(1,1): error TS2304: Cannot find name 'someFunction'. tests/cases/compiler/weird.js(1,23): error TS7006: Parameter 'BaseClass' implicitly has an 'any' type. -tests/cases/compiler/weird.js(6,13): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/weird.js(6,13): error TS2346: Call target does not contain any signatures. tests/cases/compiler/weird.js(9,17): error TS7006: Parameter 'error' implicitly has an 'any' type. @@ -16,7 +16,7 @@ tests/cases/compiler/weird.js(9,17): error TS7006: Parameter 'error' implicitly constructor() { super(); ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2346: Call target does not contain any signatures. this.foo = "bar"; } _render(error) { diff --git a/tests/baselines/reference/classWithBaseClassButNoConstructor.errors.txt b/tests/baselines/reference/classWithBaseClassButNoConstructor.errors.txt index 75f24d8c45a..da4c3a16f8b 100644 --- a/tests/baselines/reference/classWithBaseClassButNoConstructor.errors.txt +++ b/tests/baselines/reference/classWithBaseClassButNoConstructor.errors.txt @@ -1,7 +1,7 @@ -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(10,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(22,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(31,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(39,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(10,9): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(22,9): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(31,10): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts(39,10): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseClassButNoConstructor.ts (4 errors) ==== @@ -16,7 +16,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseCl var r = C; var c = new C(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var c2 = new C(1); // ok class Base2 { @@ -30,7 +30,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseCl var r2 = D; var d = new D(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var d2 = new D(1); // ok // specialized base class @@ -41,7 +41,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseCl var r3 = D2; var d3 = new D(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var d4 = new D(1); // ok class D3 extends Base2 { @@ -51,5 +51,5 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithBaseCl var r4 = D3; var d5 = new D(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var d6 = new D(1); // ok \ No newline at end of file diff --git a/tests/baselines/reference/classWithConstructors.errors.txt b/tests/baselines/reference/classWithConstructors.errors.txt index 61e0b1248b1..870d8ef13da 100644 --- a/tests/baselines/reference/classWithConstructors.errors.txt +++ b/tests/baselines/reference/classWithConstructors.errors.txt @@ -1,9 +1,9 @@ -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(6,13): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(15,14): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(21,13): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(31,13): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(40,14): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(46,13): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(6,13): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(15,14): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(21,13): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(31,13): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(40,14): error TS2554: Expected 1-2 arguments, but got 0. +tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts(46,13): error TS2554: Expected 1-2 arguments, but got 0. ==== tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstructors.ts (6 errors) ==== @@ -14,7 +14,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstr var c = new C(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var c2 = new C(''); // ok class C2 { @@ -25,7 +25,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstr var c3 = new C2(); // error ~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var c4 = new C2(''); // ok var c5 = new C2(1); // ok @@ -33,7 +33,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstr var d = new D(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var d2 = new D(1); // ok var d3 = new D(''); // ok } @@ -45,7 +45,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstr var c = new C(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var c2 = new C(''); // ok class C2 { @@ -56,7 +56,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstr var c3 = new C2(); // error ~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. var c4 = new C2(''); // ok var c5 = new C2(1, 2); // ok @@ -64,7 +64,7 @@ tests/cases/conformance/classes/members/constructorFunctionTypes/classWithConstr var d = new D(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. var d2 = new D(1); // ok var d3 = new D(''); // ok } \ No newline at end of file diff --git a/tests/baselines/reference/classWithoutExplicitConstructor.errors.txt b/tests/baselines/reference/classWithoutExplicitConstructor.errors.txt index 981f38f017c..4064a1a11e3 100644 --- a/tests/baselines/reference/classWithoutExplicitConstructor.errors.txt +++ b/tests/baselines/reference/classWithoutExplicitConstructor.errors.txt @@ -1,5 +1,5 @@ -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/classWithoutExplicitConstructor.ts(7,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/classWithoutExplicitConstructor.ts(15,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/classWithoutExplicitConstructor.ts(7,10): error TS2554: Expected 0 arguments, but got 1. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/classWithoutExplicitConstructor.ts(15,10): error TS2554: Expected 0 arguments, but got 1. ==== tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/classWithoutExplicitConstructor.ts (2 errors) ==== @@ -11,7 +11,7 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/cl var c = new C(); var c2 = new C(null); // error ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. class D { x = 2 @@ -21,4 +21,4 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/cl var d = new D(); var d2 = new D(null); // error ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 0 arguments, but got 1. \ No newline at end of file diff --git a/tests/baselines/reference/cloduleTest2.errors.txt b/tests/baselines/reference/cloduleTest2.errors.txt index 9659b5b0d4c..6a3c763ee58 100644 --- a/tests/baselines/reference/cloduleTest2.errors.txt +++ b/tests/baselines/reference/cloduleTest2.errors.txt @@ -1,11 +1,11 @@ -tests/cases/compiler/cloduleTest2.ts(4,13): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/cloduleTest2.ts(10,13): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/cloduleTest2.ts(4,13): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/cloduleTest2.ts(10,13): error TS2554: Expected 1 arguments, but got 0. tests/cases/compiler/cloduleTest2.ts(18,7): error TS2339: Property 'bar' does not exist on type 'm3d'. tests/cases/compiler/cloduleTest2.ts(19,7): error TS2339: Property 'y' does not exist on type 'm3d'. tests/cases/compiler/cloduleTest2.ts(27,7): error TS2339: Property 'bar' does not exist on type 'm3d'. tests/cases/compiler/cloduleTest2.ts(28,7): error TS2339: Property 'y' does not exist on type 'm3d'. -tests/cases/compiler/cloduleTest2.ts(33,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/cloduleTest2.ts(36,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/cloduleTest2.ts(33,9): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/cloduleTest2.ts(36,10): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/cloduleTest2.ts (8 errors) ==== @@ -14,7 +14,7 @@ tests/cases/compiler/cloduleTest2.ts(36,10): error TS2346: Supplied parameters d declare class m3d { constructor(foo); foo(): void ; static bar(); } var r = new m3d(); // error ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. } module T2 { @@ -22,7 +22,7 @@ tests/cases/compiler/cloduleTest2.ts(36,10): error TS2346: Supplied parameters d module m3d { export var y = 2; } var r = new m3d(); // error ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. } module T3 { @@ -55,9 +55,9 @@ tests/cases/compiler/cloduleTest2.ts(36,10): error TS2346: Supplied parameters d declare class m3d { constructor(foo); foo(): void; static bar(); } var r = new m3d(); // error ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. declare class m4d extends m3d { } var r2 = new m4d(); // error ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.errors.txt b/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.errors.txt index a70eb0e5e2c..f149bce5080 100644 --- a/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.errors.txt +++ b/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.errors.txt @@ -1,5 +1,5 @@ tests/cases/compiler/complicatedGenericRecursiveBaseClassReference.ts(1,7): error TS2506: 'S18' is referenced directly or indirectly in its own base expression. -tests/cases/compiler/complicatedGenericRecursiveBaseClassReference.ts(4,2): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/complicatedGenericRecursiveBaseClassReference.ts(4,2): error TS2554: Expected 0 arguments, but got 1. ==== tests/cases/compiler/complicatedGenericRecursiveBaseClassReference.ts (2 errors) ==== @@ -10,5 +10,5 @@ tests/cases/compiler/complicatedGenericRecursiveBaseClassReference.ts(4,2): erro } (new S18(123)).S18 = 0; ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. \ No newline at end of file diff --git a/tests/baselines/reference/constructorInvocationWithTooFewTypeArgs.errors.txt b/tests/baselines/reference/constructorInvocationWithTooFewTypeArgs.errors.txt index 8a15123dfc8..265ce4686db 100644 --- a/tests/baselines/reference/constructorInvocationWithTooFewTypeArgs.errors.txt +++ b/tests/baselines/reference/constructorInvocationWithTooFewTypeArgs.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/constructorInvocationWithTooFewTypeArgs.ts(9,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/constructorInvocationWithTooFewTypeArgs.ts(9,9): error TS2558: Expected 2 type arguments, but got 1. ==== tests/cases/compiler/constructorInvocationWithTooFewTypeArgs.ts (1 errors) ==== @@ -12,5 +12,5 @@ tests/cases/compiler/constructorInvocationWithTooFewTypeArgs.ts(9,9): error TS23 var d = new D(); ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. \ No newline at end of file diff --git a/tests/baselines/reference/couldNotSelectGenericOverload.errors.txt b/tests/baselines/reference/couldNotSelectGenericOverload.errors.txt index bafa2bc4237..c351245ef11 100644 --- a/tests/baselines/reference/couldNotSelectGenericOverload.errors.txt +++ b/tests/baselines/reference/couldNotSelectGenericOverload.errors.txt @@ -1,5 +1,5 @@ -tests/cases/compiler/couldNotSelectGenericOverload.ts(3,11): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/couldNotSelectGenericOverload.ts(7,11): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/couldNotSelectGenericOverload.ts(3,11): error TS2554: Expected 1 arguments, but got 2. +tests/cases/compiler/couldNotSelectGenericOverload.ts(7,11): error TS2554: Expected 1 arguments, but got 2. ==== tests/cases/compiler/couldNotSelectGenericOverload.ts (2 errors) ==== @@ -7,11 +7,11 @@ tests/cases/compiler/couldNotSelectGenericOverload.ts(7,11): error TS2346: Suppl var b = [1, ""]; var b1G = makeArray(1, ""); // any, no error ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. var b2G = makeArray(b); // any[] function makeArray2(items: any[]): any[] { return items; } var b3G = makeArray2(1, ""); // error ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. \ No newline at end of file diff --git a/tests/baselines/reference/decoratorOnClass8.errors.txt b/tests/baselines/reference/decoratorOnClass8.errors.txt index f9ca7fca210..4c13520364b 100644 --- a/tests/baselines/reference/decoratorOnClass8.errors.txt +++ b/tests/baselines/reference/decoratorOnClass8.errors.txt @@ -1,5 +1,4 @@ tests/cases/conformance/decorators/class/decoratorOnClass8.ts(3,1): error TS1238: Unable to resolve signature of class decorator when called as an expression. - Supplied parameters do not match any signature of call target. ==== tests/cases/conformance/decorators/class/decoratorOnClass8.ts (1 errors) ==== @@ -8,6 +7,5 @@ tests/cases/conformance/decorators/class/decoratorOnClass8.ts(3,1): error TS1238 @dec() ~~~~~~ !!! error TS1238: Unable to resolve signature of class decorator when called as an expression. -!!! error TS1238: Supplied parameters do not match any signature of call target. class C { } \ No newline at end of file diff --git a/tests/baselines/reference/decoratorOnClassMethod6.errors.txt b/tests/baselines/reference/decoratorOnClassMethod6.errors.txt index c8ee66717ef..530e86117ee 100644 --- a/tests/baselines/reference/decoratorOnClassMethod6.errors.txt +++ b/tests/baselines/reference/decoratorOnClassMethod6.errors.txt @@ -1,5 +1,4 @@ tests/cases/conformance/decorators/class/method/decoratorOnClassMethod6.ts(4,5): error TS1241: Unable to resolve signature of method decorator when called as an expression. - Supplied parameters do not match any signature of call target. ==== tests/cases/conformance/decorators/class/method/decoratorOnClassMethod6.ts (1 errors) ==== @@ -9,5 +8,4 @@ tests/cases/conformance/decorators/class/method/decoratorOnClassMethod6.ts(4,5): @dec ["method"]() {} ~~~~ !!! error TS1241: Unable to resolve signature of method decorator when called as an expression. -!!! error TS1241: Supplied parameters do not match any signature of call target. } \ No newline at end of file diff --git a/tests/baselines/reference/decoratorOnClassMethod8.errors.txt b/tests/baselines/reference/decoratorOnClassMethod8.errors.txt index f522dc01df9..3ada30296b6 100644 --- a/tests/baselines/reference/decoratorOnClassMethod8.errors.txt +++ b/tests/baselines/reference/decoratorOnClassMethod8.errors.txt @@ -1,5 +1,4 @@ tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts(4,5): error TS1241: Unable to resolve signature of method decorator when called as an expression. - Supplied parameters do not match any signature of call target. ==== tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts (1 errors) ==== @@ -9,5 +8,4 @@ tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts(4,5): @dec method() {} ~~~~ !!! error TS1241: Unable to resolve signature of method decorator when called as an expression. -!!! error TS1241: Supplied parameters do not match any signature of call target. } \ No newline at end of file diff --git a/tests/baselines/reference/decoratorOnClassProperty11.errors.txt b/tests/baselines/reference/decoratorOnClassProperty11.errors.txt index 6ff700564e8..2a72fefa53e 100644 --- a/tests/baselines/reference/decoratorOnClassProperty11.errors.txt +++ b/tests/baselines/reference/decoratorOnClassProperty11.errors.txt @@ -1,5 +1,4 @@ tests/cases/conformance/decorators/class/property/decoratorOnClassProperty11.ts(4,5): error TS1240: Unable to resolve signature of property decorator when called as an expression. - Supplied parameters do not match any signature of call target. ==== tests/cases/conformance/decorators/class/property/decoratorOnClassProperty11.ts (1 errors) ==== @@ -9,5 +8,4 @@ tests/cases/conformance/decorators/class/property/decoratorOnClassProperty11.ts( @dec prop; ~~~~ !!! error TS1240: Unable to resolve signature of property decorator when called as an expression. -!!! error TS1240: Supplied parameters do not match any signature of call target. } \ No newline at end of file diff --git a/tests/baselines/reference/decoratorOnClassProperty6.errors.txt b/tests/baselines/reference/decoratorOnClassProperty6.errors.txt index dbb104e8cd3..b40a81fe1c9 100644 --- a/tests/baselines/reference/decoratorOnClassProperty6.errors.txt +++ b/tests/baselines/reference/decoratorOnClassProperty6.errors.txt @@ -1,5 +1,4 @@ tests/cases/conformance/decorators/class/property/decoratorOnClassProperty6.ts(4,5): error TS1240: Unable to resolve signature of property decorator when called as an expression. - Supplied parameters do not match any signature of call target. ==== tests/cases/conformance/decorators/class/property/decoratorOnClassProperty6.ts (1 errors) ==== @@ -9,5 +8,4 @@ tests/cases/conformance/decorators/class/property/decoratorOnClassProperty6.ts(4 @dec prop; ~~~~ !!! error TS1240: Unable to resolve signature of property decorator when called as an expression. -!!! error TS1240: Supplied parameters do not match any signature of call target. } \ No newline at end of file diff --git a/tests/baselines/reference/decoratorOnClassProperty7.errors.txt b/tests/baselines/reference/decoratorOnClassProperty7.errors.txt index 41396acd17e..47f8ad5ae8c 100644 --- a/tests/baselines/reference/decoratorOnClassProperty7.errors.txt +++ b/tests/baselines/reference/decoratorOnClassProperty7.errors.txt @@ -1,5 +1,4 @@ tests/cases/conformance/decorators/class/property/decoratorOnClassProperty7.ts(4,5): error TS1240: Unable to resolve signature of property decorator when called as an expression. - Supplied parameters do not match any signature of call target. ==== tests/cases/conformance/decorators/class/property/decoratorOnClassProperty7.ts (1 errors) ==== @@ -9,5 +8,4 @@ tests/cases/conformance/decorators/class/property/decoratorOnClassProperty7.ts(4 @dec prop; ~~~~ !!! error TS1240: Unable to resolve signature of property decorator when called as an expression. -!!! error TS1240: Supplied parameters do not match any signature of call target. } \ No newline at end of file diff --git a/tests/baselines/reference/derivedClassWithoutExplicitConstructor.errors.txt b/tests/baselines/reference/derivedClassWithoutExplicitConstructor.errors.txt index 75720d86404..b8fa513e289 100644 --- a/tests/baselines/reference/derivedClassWithoutExplicitConstructor.errors.txt +++ b/tests/baselines/reference/derivedClassWithoutExplicitConstructor.errors.txt @@ -1,5 +1,5 @@ -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor.ts(11,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor.ts(24,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor.ts(11,9): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor.ts(24,9): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor.ts (2 errors) ==== @@ -15,7 +15,7 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/de var r = new Derived(); // error ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var r2 = new Derived(1); class Base2 { @@ -30,5 +30,5 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/de var d = new D(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var d2 = new D(new Date()); // ok \ No newline at end of file diff --git a/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.errors.txt b/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.errors.txt index b699fb7c89e..0bf92d51f93 100644 --- a/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.errors.txt +++ b/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.errors.txt @@ -1,5 +1,5 @@ -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor2.ts(13,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor2.ts(30,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor2.ts(13,9): error TS2554: Expected 1-3 arguments, but got 0. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor2.ts(30,9): error TS2554: Expected 1-3 arguments, but got 0. ==== tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor2.ts (2 errors) ==== @@ -17,7 +17,7 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/de var r = new Derived(); // error ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 0. var r2 = new Derived(1); var r3 = new Derived(1, 2); var r4 = new Derived(1, 2, 3); @@ -36,7 +36,7 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/de var d = new D(); // error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 0. var d2 = new D(new Date()); // ok var d3 = new D(new Date(), new Date()); var d4 = new D(new Date(), new Date(), new Date()); \ No newline at end of file diff --git a/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.errors.txt b/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.errors.txt index 6b9619cdac6..79b8cd23606 100644 --- a/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.errors.txt +++ b/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.errors.txt @@ -1,7 +1,7 @@ -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(21,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(22,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(44,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(45,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(21,9): error TS2554: Expected 2 arguments, but got 0. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(22,10): error TS2554: Expected 2 arguments, but got 1. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(44,9): error TS2554: Expected 2 arguments, but got 0. +tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts(45,10): error TS2554: Expected 2 arguments, but got 1. ==== tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/derivedClassWithoutExplicitConstructor3.ts (4 errors) ==== @@ -27,10 +27,10 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/de var r = new Derived(); // error ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 0. var r2 = new Derived2(1); // error ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. var r3 = new Derived('', ''); class Base2 { @@ -54,8 +54,8 @@ tests/cases/conformance/classes/constructorDeclarations/automaticConstructors/de var d = new D2(); // error ~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 0. var d2 = new D2(new Date()); // error ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. var d3 = new D2(new Date(), new Date()); // ok \ No newline at end of file diff --git a/tests/baselines/reference/derivedTypeCallingBaseImplWithOptionalParams.errors.txt b/tests/baselines/reference/derivedTypeCallingBaseImplWithOptionalParams.errors.txt index 3410867f818..ba1b05944fd 100644 --- a/tests/baselines/reference/derivedTypeCallingBaseImplWithOptionalParams.errors.txt +++ b/tests/baselines/reference/derivedTypeCallingBaseImplWithOptionalParams.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/derivedTypeCallingBaseImplWithOptionalParams.ts(13,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/derivedTypeCallingBaseImplWithOptionalParams.ts(13,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/derivedTypeCallingBaseImplWithOptionalParams.ts (1 errors) ==== @@ -16,4 +16,4 @@ tests/cases/compiler/derivedTypeCallingBaseImplWithOptionalParams.ts(13,1): erro var y: MyClass = new MyClass(); y.myMethod(); // error ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/emptyTypeArgumentList.errors.txt b/tests/baselines/reference/emptyTypeArgumentList.errors.txt index 9f252b127a1..036f307447b 100644 --- a/tests/baselines/reference/emptyTypeArgumentList.errors.txt +++ b/tests/baselines/reference/emptyTypeArgumentList.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/emptyTypeArgumentList.ts(2,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/emptyTypeArgumentList.ts(2,1): error TS2558: Expected 1 type arguments, but got 0. tests/cases/compiler/emptyTypeArgumentList.ts(2,4): error TS1099: Type argument list cannot be empty. @@ -6,6 +6,6 @@ tests/cases/compiler/emptyTypeArgumentList.ts(2,4): error TS1099: Type argument function foo() { } foo<>(); ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1 type arguments, but got 0. ~~ !!! error TS1099: Type argument list cannot be empty. \ No newline at end of file diff --git a/tests/baselines/reference/emptyTypeArgumentListWithNew.errors.txt b/tests/baselines/reference/emptyTypeArgumentListWithNew.errors.txt index 799e35d0d47..648aa7c6c50 100644 --- a/tests/baselines/reference/emptyTypeArgumentListWithNew.errors.txt +++ b/tests/baselines/reference/emptyTypeArgumentListWithNew.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/emptyTypeArgumentListWithNew.ts(2,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/emptyTypeArgumentListWithNew.ts(2,1): error TS2558: Expected 1 type arguments, but got 0. tests/cases/compiler/emptyTypeArgumentListWithNew.ts(2,8): error TS1099: Type argument list cannot be empty. @@ -6,6 +6,6 @@ tests/cases/compiler/emptyTypeArgumentListWithNew.ts(2,8): error TS1099: Type ar class foo { } new foo<>(); ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1 type arguments, but got 0. ~~ !!! error TS1099: Type argument list cannot be empty. \ No newline at end of file diff --git a/tests/baselines/reference/errorForwardReferenceForwadingConstructor.errors.txt b/tests/baselines/reference/errorForwardReferenceForwadingConstructor.errors.txt index f0976ba7398..27e8791f5d2 100644 --- a/tests/baselines/reference/errorForwardReferenceForwadingConstructor.errors.txt +++ b/tests/baselines/reference/errorForwardReferenceForwadingConstructor.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/errorForwardReferenceForwadingConstructor.ts(4,14): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/errorForwardReferenceForwadingConstructor.ts(4,14): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/errorForwardReferenceForwadingConstructor.ts (1 errors) ==== @@ -7,7 +7,7 @@ tests/cases/compiler/errorForwardReferenceForwadingConstructor.ts(4,14): error T function f() { var d1 = new derived(); ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var d2 = new derived(4); } diff --git a/tests/baselines/reference/functionCall11.errors.txt b/tests/baselines/reference/functionCall11.errors.txt index f1a5949acd7..e7dc72b1488 100644 --- a/tests/baselines/reference/functionCall11.errors.txt +++ b/tests/baselines/reference/functionCall11.errors.txt @@ -1,6 +1,6 @@ -tests/cases/compiler/functionCall11.ts(4,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall11.ts(4,1): error TS2554: Expected 1-2 arguments, but got 0. tests/cases/compiler/functionCall11.ts(5,5): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. -tests/cases/compiler/functionCall11.ts(6,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall11.ts(6,1): error TS2554: Expected 1-2 arguments, but got 3. ==== tests/cases/compiler/functionCall11.ts (3 errors) ==== @@ -9,11 +9,11 @@ tests/cases/compiler/functionCall11.ts(6,1): error TS2346: Supplied parameters d foo('foo'); foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. foo(1, 'bar'); ~ !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. foo('foo', 1, 'bar'); ~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 3. \ No newline at end of file diff --git a/tests/baselines/reference/functionCall12.errors.txt b/tests/baselines/reference/functionCall12.errors.txt index ef93a34b080..3c22d0dcef7 100644 --- a/tests/baselines/reference/functionCall12.errors.txt +++ b/tests/baselines/reference/functionCall12.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/functionCall12.ts(4,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall12.ts(4,1): error TS2554: Expected 1-3 arguments, but got 0. tests/cases/compiler/functionCall12.ts(5,5): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. tests/cases/compiler/functionCall12.ts(7,15): error TS2345: Argument of type '3' is not assignable to parameter of type 'string'. @@ -9,7 +9,7 @@ tests/cases/compiler/functionCall12.ts(7,15): error TS2345: Argument of type '3' foo('foo'); foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 0. foo(1, 'bar'); ~ !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. diff --git a/tests/baselines/reference/functionCall13.errors.txt b/tests/baselines/reference/functionCall13.errors.txt index a89d7fc1efa..c53f63b7d78 100644 --- a/tests/baselines/reference/functionCall13.errors.txt +++ b/tests/baselines/reference/functionCall13.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/functionCall13.ts(4,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall13.ts(4,1): error TS2555: Expected at least 1 arguments, but got 0. tests/cases/compiler/functionCall13.ts(5,5): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. @@ -8,7 +8,7 @@ tests/cases/compiler/functionCall13.ts(5,5): error TS2345: Argument of type '1' foo('foo'); foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2555: Expected at least 1 arguments, but got 0. foo(1, 'bar'); ~ !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. diff --git a/tests/baselines/reference/functionCall16.errors.txt b/tests/baselines/reference/functionCall16.errors.txt index d338c1305dd..b3345d82779 100644 --- a/tests/baselines/reference/functionCall16.errors.txt +++ b/tests/baselines/reference/functionCall16.errors.txt @@ -1,5 +1,5 @@ tests/cases/compiler/functionCall16.ts(2,12): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. -tests/cases/compiler/functionCall16.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall16.ts(5,1): error TS2555: Expected at least 1 arguments, but got 0. tests/cases/compiler/functionCall16.ts(6,5): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. @@ -12,7 +12,7 @@ tests/cases/compiler/functionCall16.ts(6,5): error TS2345: Argument of type '1' foo('foo', 'bar'); foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2555: Expected at least 1 arguments, but got 0. foo(1, 'bar'); ~ !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. diff --git a/tests/baselines/reference/functionCall17.errors.txt b/tests/baselines/reference/functionCall17.errors.txt index f266554b518..c672c092677 100644 --- a/tests/baselines/reference/functionCall17.errors.txt +++ b/tests/baselines/reference/functionCall17.errors.txt @@ -1,5 +1,5 @@ tests/cases/compiler/functionCall17.ts(2,12): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. -tests/cases/compiler/functionCall17.ts(4,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall17.ts(4,1): error TS2555: Expected at least 1 arguments, but got 0. tests/cases/compiler/functionCall17.ts(5,5): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. tests/cases/compiler/functionCall17.ts(6,12): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. @@ -12,7 +12,7 @@ tests/cases/compiler/functionCall17.ts(6,12): error TS2345: Argument of type '1' foo('foo'); foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2555: Expected at least 1 arguments, but got 0. foo(1, 'bar'); ~ !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. diff --git a/tests/baselines/reference/functionCall6.errors.txt b/tests/baselines/reference/functionCall6.errors.txt index 3d590d8f5c2..5200a5a3e6f 100644 --- a/tests/baselines/reference/functionCall6.errors.txt +++ b/tests/baselines/reference/functionCall6.errors.txt @@ -1,6 +1,6 @@ tests/cases/compiler/functionCall6.ts(3,5): error TS2345: Argument of type '2' is not assignable to parameter of type 'string'. -tests/cases/compiler/functionCall6.ts(4,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/functionCall6.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall6.ts(4,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/compiler/functionCall6.ts(5,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/functionCall6.ts (3 errors) ==== @@ -11,8 +11,8 @@ tests/cases/compiler/functionCall6.ts(5,1): error TS2346: Supplied parameters do !!! error TS2345: Argument of type '2' is not assignable to parameter of type 'string'. foo('foo', 'bar'); ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/functionCall7.errors.txt b/tests/baselines/reference/functionCall7.errors.txt index 138c5f62f16..78f2a3384db 100644 --- a/tests/baselines/reference/functionCall7.errors.txt +++ b/tests/baselines/reference/functionCall7.errors.txt @@ -1,6 +1,6 @@ -tests/cases/compiler/functionCall7.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall7.ts(5,1): error TS2554: Expected 1 arguments, but got 2. tests/cases/compiler/functionCall7.ts(6,5): error TS2345: Argument of type '4' is not assignable to parameter of type 'c1'. -tests/cases/compiler/functionCall7.ts(7,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall7.ts(7,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/functionCall7.ts (3 errors) ==== @@ -10,11 +10,11 @@ tests/cases/compiler/functionCall7.ts(7,1): error TS2346: Supplied parameters do foo(myC); foo(myC, myC); ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. foo(4); ~ !!! error TS2345: Argument of type '4' is not assignable to parameter of type 'c1'. foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/functionCall8.errors.txt b/tests/baselines/reference/functionCall8.errors.txt index 7cf197d5812..86e01baa740 100644 --- a/tests/baselines/reference/functionCall8.errors.txt +++ b/tests/baselines/reference/functionCall8.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/functionCall8.ts(3,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall8.ts(3,1): error TS2554: Expected 0-1 arguments, but got 2. tests/cases/compiler/functionCall8.ts(4,5): error TS2345: Argument of type '4' is not assignable to parameter of type 'string'. @@ -7,7 +7,7 @@ tests/cases/compiler/functionCall8.ts(4,5): error TS2345: Argument of type '4' i foo('foo'); foo('foo', 'bar'); ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-1 arguments, but got 2. foo(4); ~ !!! error TS2345: Argument of type '4' is not assignable to parameter of type 'string'. diff --git a/tests/baselines/reference/functionCall9.errors.txt b/tests/baselines/reference/functionCall9.errors.txt index 83cda64e204..50c33a15aad 100644 --- a/tests/baselines/reference/functionCall9.errors.txt +++ b/tests/baselines/reference/functionCall9.errors.txt @@ -1,5 +1,5 @@ tests/cases/compiler/functionCall9.ts(4,11): error TS2345: Argument of type '"bar"' is not assignable to parameter of type 'number'. -tests/cases/compiler/functionCall9.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionCall9.ts(5,1): error TS2554: Expected 0-2 arguments, but got 3. ==== tests/cases/compiler/functionCall9.ts (2 errors) ==== @@ -11,5 +11,5 @@ tests/cases/compiler/functionCall9.ts(5,1): error TS2346: Supplied parameters do !!! error TS2345: Argument of type '"bar"' is not assignable to parameter of type 'number'. foo('foo', 1, 'bar'); ~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-2 arguments, but got 3. foo(); \ No newline at end of file diff --git a/tests/baselines/reference/functionConstraintSatisfaction2.errors.txt b/tests/baselines/reference/functionConstraintSatisfaction2.errors.txt index 06cdca868ad..f87312634f8 100644 --- a/tests/baselines/reference/functionConstraintSatisfaction2.errors.txt +++ b/tests/baselines/reference/functionConstraintSatisfaction2.errors.txt @@ -1,6 +1,6 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstraintSatisfaction2.ts(5,5): error TS2345: Argument of type '1' is not assignable to parameter of type 'Function'. -tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstraintSatisfaction2.ts(6,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstraintSatisfaction2.ts(7,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstraintSatisfaction2.ts(6,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstraintSatisfaction2.ts(7,1): error TS2554: Expected 1 arguments, but got 2. tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstraintSatisfaction2.ts(23,14): error TS2345: Argument of type 'Function' is not assignable to parameter of type '(x: string) => string'. Type 'Function' provides no match for the signature '(x: string): string'. tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstraintSatisfaction2.ts(24,15): error TS2345: Argument of type '(x: string[]) => string[]' is not assignable to parameter of type '(x: string) => string'. @@ -36,10 +36,10 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/functionConstrain !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'Function'. foo(() => { }, 1); ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. foo(1, () => { }); ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. function foo2 string>(x: T): T { return x; } diff --git a/tests/baselines/reference/functionOverloads29.errors.txt b/tests/baselines/reference/functionOverloads29.errors.txt index 763405e351b..2423f53165f 100644 --- a/tests/baselines/reference/functionOverloads29.errors.txt +++ b/tests/baselines/reference/functionOverloads29.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/functionOverloads29.ts(4,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionOverloads29.ts(4,9): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/functionOverloads29.ts (1 errors) ==== @@ -7,5 +7,5 @@ tests/cases/compiler/functionOverloads29.ts(4,9): error TS2346: Supplied paramet function foo(bar:any):any{ return bar } var x = foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/functionOverloads34.errors.txt b/tests/baselines/reference/functionOverloads34.errors.txt index ccd771d2130..c47eabef592 100644 --- a/tests/baselines/reference/functionOverloads34.errors.txt +++ b/tests/baselines/reference/functionOverloads34.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/functionOverloads34.ts(4,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionOverloads34.ts(4,9): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/functionOverloads34.ts (1 errors) ==== @@ -7,5 +7,5 @@ tests/cases/compiler/functionOverloads34.ts(4,9): error TS2346: Supplied paramet function foo(bar:{a:any;}):any{ return bar } var x = foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/functionOverloads37.errors.txt b/tests/baselines/reference/functionOverloads37.errors.txt index 742e1bedb22..523c4912e80 100644 --- a/tests/baselines/reference/functionOverloads37.errors.txt +++ b/tests/baselines/reference/functionOverloads37.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/functionOverloads37.ts(4,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/functionOverloads37.ts(4,9): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/functionOverloads37.ts (1 errors) ==== @@ -7,5 +7,5 @@ tests/cases/compiler/functionOverloads37.ts(4,9): error TS2346: Supplied paramet function foo(bar:{a:any;}[]):any{ return bar } var x = foo(); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/genericCallbackInvokedInsideItsContainingFunction1.errors.txt b/tests/baselines/reference/genericCallbackInvokedInsideItsContainingFunction1.errors.txt index aec6b9c34b7..7ff051bd63e 100644 --- a/tests/baselines/reference/genericCallbackInvokedInsideItsContainingFunction1.errors.txt +++ b/tests/baselines/reference/genericCallbackInvokedInsideItsContainingFunction1.errors.txt @@ -1,33 +1,33 @@ -tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(2,14): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(2,14): error TS2558: Expected 0 type arguments, but got 1. tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(3,16): error TS2345: Argument of type '1' is not assignable to parameter of type 'T'. -tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(4,14): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(8,15): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(9,15): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(4,14): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(8,15): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(9,15): error TS2558: Expected 0 type arguments, but got 1. tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(12,17): error TS2345: Argument of type 'U' is not assignable to parameter of type 'T'. -tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(13,15): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(14,15): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(13,15): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(14,15): error TS2558: Expected 0 type arguments, but got 1. ==== tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts (8 errors) ==== function foo(x:T, y:U, f: (v: T) => U) { var r1 = f(1); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r2 = f(1); ~ !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'T'. var r3 = f(null); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r4 = f(null); var r11 = f(x); var r21 = f(x); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r31 = f(null); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r41 = f(null); var r12 = f(y); @@ -35,9 +35,9 @@ tests/cases/compiler/genericCallbackInvokedInsideItsContainingFunction1.ts(14,15 !!! error TS2345: Argument of type 'U' is not assignable to parameter of type 'T'. var r22 = f(y); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r32 = f(null); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r42 = f(null); } \ No newline at end of file diff --git a/tests/baselines/reference/genericDefaultsErrors.errors.txt b/tests/baselines/reference/genericDefaultsErrors.errors.txt index 3d792f022ac..6200046c49f 100644 --- a/tests/baselines/reference/genericDefaultsErrors.errors.txt +++ b/tests/baselines/reference/genericDefaultsErrors.errors.txt @@ -3,8 +3,8 @@ tests/cases/compiler/genericDefaultsErrors.ts(4,59): error TS2344: Type 'T' does Type 'string' is not assignable to type 'number'. tests/cases/compiler/genericDefaultsErrors.ts(5,44): error TS2344: Type 'T' does not satisfy the constraint 'number'. tests/cases/compiler/genericDefaultsErrors.ts(6,39): error TS2344: Type 'number' does not satisfy the constraint 'T'. -tests/cases/compiler/genericDefaultsErrors.ts(10,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/genericDefaultsErrors.ts(13,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/genericDefaultsErrors.ts(10,1): error TS2558: Expected 2-3 type arguments, but got 1. +tests/cases/compiler/genericDefaultsErrors.ts(13,1): error TS2558: Expected 2-3 type arguments, but got 4. tests/cases/compiler/genericDefaultsErrors.ts(17,13): error TS2345: Argument of type '"a"' is not assignable to parameter of type 'number'. tests/cases/compiler/genericDefaultsErrors.ts(19,11): error TS2428: All declarations of 'i00' must have identical type parameters. tests/cases/compiler/genericDefaultsErrors.ts(20,11): error TS2428: All declarations of 'i00' must have identical type parameters. @@ -44,12 +44,12 @@ tests/cases/compiler/genericDefaultsErrors.ts(38,20): error TS4033: Property 'x' f11(); // ok f11<1>(); // error ~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2-3 type arguments, but got 1. f11<1, 2>(); // ok f11<1, 2, 3>(); // ok f11<1, 2, 3, 4>(); // error ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2-3 type arguments, but got 4. declare function f12(a?: U): void; f12(); // ok diff --git a/tests/baselines/reference/genericFunctionsWithOptionalParameters2.errors.txt b/tests/baselines/reference/genericFunctionsWithOptionalParameters2.errors.txt index 5b9ed348583..d7dfc18d40f 100644 --- a/tests/baselines/reference/genericFunctionsWithOptionalParameters2.errors.txt +++ b/tests/baselines/reference/genericFunctionsWithOptionalParameters2.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/genericFunctionsWithOptionalParameters2.ts(7,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/genericFunctionsWithOptionalParameters2.ts(7,1): error TS2554: Expected 1-3 arguments, but got 0. ==== tests/cases/compiler/genericFunctionsWithOptionalParameters2.ts (1 errors) ==== @@ -10,7 +10,7 @@ tests/cases/compiler/genericFunctionsWithOptionalParameters2.ts(7,1): error TS23 utils.fold(); // error ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 0. utils.fold(null); // no error utils.fold(null, null); // no error utils.fold(null, null, null); // error: Unable to invoke type with no call signatures diff --git a/tests/baselines/reference/genericWithOpenTypeParameters1.errors.txt b/tests/baselines/reference/genericWithOpenTypeParameters1.errors.txt index ba9ec881f99..9f8694d2fca 100644 --- a/tests/baselines/reference/genericWithOpenTypeParameters1.errors.txt +++ b/tests/baselines/reference/genericWithOpenTypeParameters1.errors.txt @@ -1,6 +1,6 @@ tests/cases/compiler/genericWithOpenTypeParameters1.ts(7,40): error TS2345: Argument of type '1' is not assignable to parameter of type 'T'. -tests/cases/compiler/genericWithOpenTypeParameters1.ts(8,35): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/genericWithOpenTypeParameters1.ts(9,35): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/genericWithOpenTypeParameters1.ts(8,35): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/compiler/genericWithOpenTypeParameters1.ts(9,35): error TS2558: Expected 0 type arguments, but got 1. ==== tests/cases/compiler/genericWithOpenTypeParameters1.ts (3 errors) ==== @@ -15,9 +15,9 @@ tests/cases/compiler/genericWithOpenTypeParameters1.ts(9,35): error TS2346: Supp !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'T'. var f2 = (x: B) => { return x.foo(1); } // error ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var f3 = (x: B) => { return x.foo(1); } // error ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var f4 = (x: B) => { return x.foo(1); } // no error \ No newline at end of file diff --git a/tests/baselines/reference/grammarAmbiguities.errors.txt b/tests/baselines/reference/grammarAmbiguities.errors.txt index 3d21f10de7b..d3d0637bd2c 100644 --- a/tests/baselines/reference/grammarAmbiguities.errors.txt +++ b/tests/baselines/reference/grammarAmbiguities.errors.txt @@ -1,5 +1,5 @@ -tests/cases/conformance/expressions/functionCalls/grammarAmbiguities.ts(8,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/expressions/functionCalls/grammarAmbiguities.ts(9,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/expressions/functionCalls/grammarAmbiguities.ts(8,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/expressions/functionCalls/grammarAmbiguities.ts(9,1): error TS2554: Expected 1 arguments, but got 2. ==== tests/cases/conformance/expressions/functionCalls/grammarAmbiguities.ts (2 errors) ==== @@ -12,9 +12,9 @@ tests/cases/conformance/expressions/functionCalls/grammarAmbiguities.ts(9,1): er f(g(7)); f(g < A, B > 7); // Should error ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. f(g < A, B > +(7)); // Should error ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. \ No newline at end of file diff --git a/tests/baselines/reference/grammarAmbiguities1.errors.txt b/tests/baselines/reference/grammarAmbiguities1.errors.txt index 12df5f3c1e0..22467d7ee77 100644 --- a/tests/baselines/reference/grammarAmbiguities1.errors.txt +++ b/tests/baselines/reference/grammarAmbiguities1.errors.txt @@ -1,7 +1,7 @@ -tests/cases/compiler/grammarAmbiguities1.ts(8,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/grammarAmbiguities1.ts(8,1): error TS2554: Expected 1 arguments, but got 2. tests/cases/compiler/grammarAmbiguities1.ts(8,3): error TS2365: Operator '<' cannot be applied to types '(x: any) => any' and 'typeof A'. tests/cases/compiler/grammarAmbiguities1.ts(8,10): error TS2365: Operator '>' cannot be applied to types 'typeof B' and 'number'. -tests/cases/compiler/grammarAmbiguities1.ts(9,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/grammarAmbiguities1.ts(9,1): error TS2554: Expected 1 arguments, but got 2. tests/cases/compiler/grammarAmbiguities1.ts(9,3): error TS2365: Operator '<' cannot be applied to types '(x: any) => any' and 'typeof A'. tests/cases/compiler/grammarAmbiguities1.ts(9,10): error TS2365: Operator '>' cannot be applied to types 'typeof B' and 'number'. @@ -16,14 +16,14 @@ tests/cases/compiler/grammarAmbiguities1.ts(9,10): error TS2365: Operator '>' ca f(g(7)); f(g < A, B > 7); ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. ~~~~~ !!! error TS2365: Operator '<' cannot be applied to types '(x: any) => any' and 'typeof A'. ~~~~~ !!! error TS2365: Operator '>' cannot be applied to types 'typeof B' and 'number'. f(g < A, B > +(7)); ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. ~~~~~ !!! error TS2365: Operator '<' cannot be applied to types '(x: any) => any' and 'typeof A'. ~~~~~~~~ diff --git a/tests/baselines/reference/instantiateGenericClassWithWrongNumberOfTypeArguments.errors.txt b/tests/baselines/reference/instantiateGenericClassWithWrongNumberOfTypeArguments.errors.txt index 5162cd28fd5..05cc1ee1cd0 100644 --- a/tests/baselines/reference/instantiateGenericClassWithWrongNumberOfTypeArguments.errors.txt +++ b/tests/baselines/reference/instantiateGenericClassWithWrongNumberOfTypeArguments.errors.txt @@ -1,5 +1,5 @@ -tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateGenericClassWithWrongNumberOfTypeArguments.ts(8,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateGenericClassWithWrongNumberOfTypeArguments.ts(16,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateGenericClassWithWrongNumberOfTypeArguments.ts(8,9): error TS2558: Expected 1 type arguments, but got 2. +tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateGenericClassWithWrongNumberOfTypeArguments.ts(16,9): error TS2558: Expected 2 type arguments, but got 1. ==== tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateGenericClassWithWrongNumberOfTypeArguments.ts (2 errors) ==== @@ -12,7 +12,7 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateGeneri var c = new C(); ~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1 type arguments, but got 2. class D { x: T @@ -22,4 +22,4 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateGeneri // BUG 794238 var d = new D(); ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2558: Expected 2 type arguments, but got 1. \ No newline at end of file diff --git a/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.errors.txt b/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.errors.txt index 8322fd3b2e4..196af18aa9a 100644 --- a/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.errors.txt +++ b/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.errors.txt @@ -1,8 +1,8 @@ -tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(8,9): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(11,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(8,9): error TS2558: Expected 0 type arguments, but got 1. tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(11,9): error TS2350: Only a void function can be called with the 'new' keyword. -tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(14,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(11,9): error TS2558: Expected 0 type arguments, but got 1. tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(14,10): error TS2350: Only a void function can be called with the 'new' keyword. +tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(14,10): error TS2558: Expected 0 type arguments, but got 1. tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGenericTypeWithTypeArguments.ts(18,10): error TS2347: Untyped function calls may not accept type arguments. @@ -16,21 +16,21 @@ tests/cases/conformance/types/typeParameters/typeArgumentLists/instantiateNonGen var c = new C(); ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. function Foo(): void { } var r = new Foo(); ~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. - ~~~~~~~~~~~~~~~~~ !!! error TS2350: Only a void function can be called with the 'new' keyword. + ~~~~~~~~~~~~~~~~~ +!!! error TS2558: Expected 0 type arguments, but got 1. var f: { (): void }; var r2 = new f(); ~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. - ~~~~~~~~~~~~~~~ !!! error TS2350: Only a void function can be called with the 'new' keyword. + ~~~~~~~~~~~~~~~ +!!! error TS2558: Expected 0 type arguments, but got 1. var a: any; // BUG 790977 diff --git a/tests/baselines/reference/iteratorSpreadInCall.errors.txt b/tests/baselines/reference/iteratorSpreadInCall.errors.txt index d26f9ab6447..1831013b6e7 100644 --- a/tests/baselines/reference/iteratorSpreadInCall.errors.txt +++ b/tests/baselines/reference/iteratorSpreadInCall.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/es6/spread/iteratorSpreadInCall.ts(15,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/spread/iteratorSpreadInCall.ts(15,1): error TS2556: Expected 1 arguments, but got a minimum of 0. ==== tests/cases/conformance/es6/spread/iteratorSpreadInCall.ts (1 errors) ==== @@ -18,4 +18,4 @@ tests/cases/conformance/es6/spread/iteratorSpreadInCall.ts(15,1): error TS2346: foo(...new SymbolIterator); ~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2556: Expected 1 arguments, but got a minimum of 0. \ No newline at end of file diff --git a/tests/baselines/reference/iteratorSpreadInCall10.errors.txt b/tests/baselines/reference/iteratorSpreadInCall10.errors.txt index bf478012c5d..0d10c9f25e5 100644 --- a/tests/baselines/reference/iteratorSpreadInCall10.errors.txt +++ b/tests/baselines/reference/iteratorSpreadInCall10.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/es6/spread/iteratorSpreadInCall10.ts(15,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/spread/iteratorSpreadInCall10.ts(15,1): error TS2556: Expected 1 arguments, but got a minimum of 0. ==== tests/cases/conformance/es6/spread/iteratorSpreadInCall10.ts (1 errors) ==== @@ -18,4 +18,4 @@ tests/cases/conformance/es6/spread/iteratorSpreadInCall10.ts(15,1): error TS2346 foo(...new SymbolIterator); ~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2556: Expected 1 arguments, but got a minimum of 0. \ No newline at end of file diff --git a/tests/baselines/reference/iteratorSpreadInCall2.errors.txt b/tests/baselines/reference/iteratorSpreadInCall2.errors.txt index abf8fc71ed7..03cc296b8ab 100644 --- a/tests/baselines/reference/iteratorSpreadInCall2.errors.txt +++ b/tests/baselines/reference/iteratorSpreadInCall2.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/es6/spread/iteratorSpreadInCall2.ts(15,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/spread/iteratorSpreadInCall2.ts(15,1): error TS2556: Expected 1 arguments, but got a minimum of 0. ==== tests/cases/conformance/es6/spread/iteratorSpreadInCall2.ts (1 errors) ==== @@ -18,4 +18,4 @@ tests/cases/conformance/es6/spread/iteratorSpreadInCall2.ts(15,1): error TS2346: foo(...new SymbolIterator); ~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2556: Expected 1 arguments, but got a minimum of 0. \ No newline at end of file diff --git a/tests/baselines/reference/iteratorSpreadInCall4.errors.txt b/tests/baselines/reference/iteratorSpreadInCall4.errors.txt index 3beaf2ce65c..899ac1d9e90 100644 --- a/tests/baselines/reference/iteratorSpreadInCall4.errors.txt +++ b/tests/baselines/reference/iteratorSpreadInCall4.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/es6/spread/iteratorSpreadInCall4.ts(15,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/spread/iteratorSpreadInCall4.ts(15,1): error TS2557: Expected at least 1 arguments, but got a minimum of 0. ==== tests/cases/conformance/es6/spread/iteratorSpreadInCall4.ts (1 errors) ==== @@ -18,4 +18,4 @@ tests/cases/conformance/es6/spread/iteratorSpreadInCall4.ts(15,1): error TS2346: foo(...new SymbolIterator); ~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2557: Expected at least 1 arguments, but got a minimum of 0. \ No newline at end of file diff --git a/tests/baselines/reference/jsFileFunctionParametersAsOptional2.errors.txt b/tests/baselines/reference/jsFileFunctionParametersAsOptional2.errors.txt index 236827b97bc..5a308a61b0f 100644 --- a/tests/baselines/reference/jsFileFunctionParametersAsOptional2.errors.txt +++ b/tests/baselines/reference/jsFileFunctionParametersAsOptional2.errors.txt @@ -1,6 +1,6 @@ -tests/cases/compiler/bar.ts(1,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/bar.ts(2,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/bar.ts(3,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/bar.ts(1,1): error TS2554: Expected 3 arguments, but got 0. +tests/cases/compiler/bar.ts(2,1): error TS2554: Expected 3 arguments, but got 1. +tests/cases/compiler/bar.ts(3,1): error TS2554: Expected 3 arguments, but got 2. ==== tests/cases/compiler/foo.js (0 errors) ==== @@ -15,13 +15,13 @@ tests/cases/compiler/bar.ts(3,1): error TS2346: Supplied parameters do not match ==== tests/cases/compiler/bar.ts (3 errors) ==== f(); // Error ~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 3 arguments, but got 0. f(1); // Error ~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 3 arguments, but got 1. f(1, 2); // Error ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 3 arguments, but got 2. f(1, 2, 3); // OK \ No newline at end of file diff --git a/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.errors.txt b/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.errors.txt index 2fb7bd1bfbb..9b95b143d64 100644 --- a/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.errors.txt +++ b/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.errors.txt @@ -1,7 +1,7 @@ tests/cases/compiler/mismatchedExplicitTypeParameterAndArgumentType.ts(10,30): error TS2345: Argument of type '(string | number)[]' is not assignable to parameter of type 'number[]'. Type 'string | number' is not assignable to type 'number'. Type 'string' is not assignable to type 'number'. -tests/cases/compiler/mismatchedExplicitTypeParameterAndArgumentType.ts(11,11): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/mismatchedExplicitTypeParameterAndArgumentType.ts(11,11): error TS2558: Expected 2 type arguments, but got 1. ==== tests/cases/compiler/mismatchedExplicitTypeParameterAndArgumentType.ts (2 errors) ==== @@ -21,5 +21,5 @@ tests/cases/compiler/mismatchedExplicitTypeParameterAndArgumentType.ts(11,11): e !!! error TS2345: Type 'string' is not assignable to type 'number'. var r7b = map([1, ""], (x) => x.toString()); // error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 2 type arguments, but got 1. var r8 = map([1, ""], (x) => x.toString()); \ No newline at end of file diff --git a/tests/baselines/reference/optionalParamArgsTest.errors.txt b/tests/baselines/reference/optionalParamArgsTest.errors.txt index 05fefa85065..7a3e044e6fd 100644 --- a/tests/baselines/reference/optionalParamArgsTest.errors.txt +++ b/tests/baselines/reference/optionalParamArgsTest.errors.txt @@ -1,25 +1,25 @@ tests/cases/compiler/optionalParamArgsTest.ts(31,12): error TS2393: Duplicate function implementation. tests/cases/compiler/optionalParamArgsTest.ts(34,12): error TS2393: Duplicate function implementation. -tests/cases/compiler/optionalParamArgsTest.ts(98,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(99,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(100,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(101,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(102,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(103,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(104,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(105,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(106,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(107,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(108,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(109,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(110,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(111,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(112,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(113,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(114,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(115,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(116,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/optionalParamArgsTest.ts(117,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/optionalParamArgsTest.ts(98,1): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/optionalParamArgsTest.ts(99,1): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/optionalParamArgsTest.ts(100,1): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/optionalParamArgsTest.ts(101,1): error TS2554: Expected 0 arguments, but got 1. +tests/cases/compiler/optionalParamArgsTest.ts(102,1): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/optionalParamArgsTest.ts(103,1): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/optionalParamArgsTest.ts(104,1): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/optionalParamArgsTest.ts(105,1): error TS2554: Expected 1 arguments, but got 0. +tests/cases/compiler/optionalParamArgsTest.ts(106,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/compiler/optionalParamArgsTest.ts(107,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/compiler/optionalParamArgsTest.ts(108,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/compiler/optionalParamArgsTest.ts(109,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/compiler/optionalParamArgsTest.ts(110,1): error TS2554: Expected 0-2 arguments, but got 3. +tests/cases/compiler/optionalParamArgsTest.ts(111,1): error TS2554: Expected 0-2 arguments, but got 3. +tests/cases/compiler/optionalParamArgsTest.ts(112,1): error TS2554: Expected 0-2 arguments, but got 3. +tests/cases/compiler/optionalParamArgsTest.ts(113,1): error TS2554: Expected 0-2 arguments, but got 3. +tests/cases/compiler/optionalParamArgsTest.ts(114,1): error TS2554: Expected 1-2 arguments, but got 0. +tests/cases/compiler/optionalParamArgsTest.ts(115,1): error TS2554: Expected 1-2 arguments, but got 0. +tests/cases/compiler/optionalParamArgsTest.ts(116,1): error TS2554: Expected 1-2 arguments, but got 0. +tests/cases/compiler/optionalParamArgsTest.ts(117,1): error TS2554: Expected 1-2 arguments, but got 0. ==== tests/cases/compiler/optionalParamArgsTest.ts (22 errors) ==== @@ -126,64 +126,64 @@ tests/cases/compiler/optionalParamArgsTest.ts(117,1): error TS2346: Supplied par // Negative tests - we expect these cases to fail c1o1.C1M1(1); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. i1o1.C1M1(1); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. F1(1); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. L1(1); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. c1o1.C1M2(); ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. i1o1.C1M2(); ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. F2(); ~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. L2(); ~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. c1o1.C1M2(1,2); ~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. i1o1.C1M2(1,2); ~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. F2(1,2); ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. L2(1,2); ~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. c1o1.C1M3(1,2,3); ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-2 arguments, but got 3. i1o1.C1M3(1,2,3); ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-2 arguments, but got 3. F3(1,2,3); ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-2 arguments, but got 3. L3(1,2,3); ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-2 arguments, but got 3. c1o1.C1M4(); ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. i1o1.C1M4(); ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. F4(); ~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. L4(); ~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. function fnOpt1(id: number, children: number[] = [], expectedPath: number[] = [], isRoot?: boolean): void {} function fnOpt2(id: number, children?: number[], expectedPath?: number[], isRoot?: boolean): void {} diff --git a/tests/baselines/reference/overload1.errors.txt b/tests/baselines/reference/overload1.errors.txt index a88b4f81519..2f118e59f64 100644 --- a/tests/baselines/reference/overload1.errors.txt +++ b/tests/baselines/reference/overload1.errors.txt @@ -1,7 +1,7 @@ tests/cases/compiler/overload1.ts(27,5): error TS2322: Type 'C' is not assignable to type 'string'. tests/cases/compiler/overload1.ts(29,1): error TS2322: Type 'number' is not assignable to type 'string'. -tests/cases/compiler/overload1.ts(31,3): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/overload1.ts(32,3): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/overload1.ts(31,3): error TS2554: Expected 1-2 arguments, but got 3. +tests/cases/compiler/overload1.ts(32,3): error TS2554: Expected 1-2 arguments, but got 0. tests/cases/compiler/overload1.ts(33,1): error TS2322: Type 'C' is not assignable to type 'string'. tests/cases/compiler/overload1.ts(34,9): error TS2345: Argument of type '2' is not assignable to parameter of type 'string'. @@ -43,10 +43,10 @@ tests/cases/compiler/overload1.ts(34,9): error TS2345: Argument of type '2' is n var z:string=x.g(x.g(3,3)); // good z=x.g(2,2,2); // no match ~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 3. z=x.g(); // no match ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. z=x.g(new O.B()); // ambiguous (up and down conversion) ~ !!! error TS2322: Type 'C' is not assignable to type 'string'. diff --git a/tests/baselines/reference/overloadResolution.errors.txt b/tests/baselines/reference/overloadResolution.errors.txt index b8b2cdfe888..37cea935e66 100644 --- a/tests/baselines/reference/overloadResolution.errors.txt +++ b/tests/baselines/reference/overloadResolution.errors.txt @@ -1,6 +1,6 @@ tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(27,5): error TS2345: Argument of type '{}' is not assignable to parameter of type 'number'. tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(41,11): error TS2345: Argument of type '""' is not assignable to parameter of type 'number'. -tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(63,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(63,1): error TS2558: Expected 1-3 type arguments, but got 4. tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(70,21): error TS2345: Argument of type '3' is not assignable to parameter of type 'string'. tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(71,21): error TS2345: Argument of type '""' is not assignable to parameter of type 'number'. tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(81,5): error TS2344: Type 'boolean' does not satisfy the constraint 'number'. @@ -79,7 +79,7 @@ tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(91,22): // Generic overloads with differing arity called with type argument count that doesn't match any overload fn3(); // Error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1-3 type arguments, but got 4. // Generic overloads with constraints called with type arguments that satisfy the constraints function fn4(n: T, m: U); diff --git a/tests/baselines/reference/overloadResolutionClassConstructors.errors.txt b/tests/baselines/reference/overloadResolutionClassConstructors.errors.txt index 4c8e9b2513a..92f3a7cfa90 100644 --- a/tests/baselines/reference/overloadResolutionClassConstructors.errors.txt +++ b/tests/baselines/reference/overloadResolutionClassConstructors.errors.txt @@ -1,7 +1,7 @@ tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(27,9): error TS2345: Argument of type '{}' is not assignable to parameter of type 'number'. -tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(60,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(61,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(65,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(60,1): error TS2558: Expected 3 type arguments, but got 1. +tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(61,1): error TS2558: Expected 3 type arguments, but got 2. +tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(65,1): error TS2558: Expected 3 type arguments, but got 4. tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(73,25): error TS2345: Argument of type '3' is not assignable to parameter of type 'string'. tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(74,9): error TS2344: Type 'number' does not satisfy the constraint 'string'. tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstructors.ts(75,9): error TS2344: Type 'number' does not satisfy the constraint 'string'. @@ -78,16 +78,16 @@ tests/cases/conformance/expressions/functionCalls/overloadResolutionClassConstru // Generic overloads with differing arity called with type arguments matching each overload type parameter count new fn3(4); // Error ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 3 type arguments, but got 1. new fn3('', '', ''); // Error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 3 type arguments, but got 2. new fn3('', '', 3); // Generic overloads with differing arity called with type argument count that doesn't match any overload new fn3(); // Error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 3 type arguments, but got 4. // Generic overloads with constraints called with type arguments that satisfy the constraints class fn4 { diff --git a/tests/baselines/reference/overloadResolutionConstructors.errors.txt b/tests/baselines/reference/overloadResolutionConstructors.errors.txt index 9a112eaf2ef..9b09992228e 100644 --- a/tests/baselines/reference/overloadResolutionConstructors.errors.txt +++ b/tests/baselines/reference/overloadResolutionConstructors.errors.txt @@ -1,6 +1,6 @@ tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts(27,9): error TS2345: Argument of type '{}' is not assignable to parameter of type 'number'. tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts(43,15): error TS2345: Argument of type '""' is not assignable to parameter of type 'number'. -tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts(67,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts(67,1): error TS2558: Expected 1-3 type arguments, but got 4. tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts(77,25): error TS2345: Argument of type '3' is not assignable to parameter of type 'string'. tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts(78,25): error TS2345: Argument of type '""' is not assignable to parameter of type 'number'. tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts(88,9): error TS2344: Type 'boolean' does not satisfy the constraint 'number'. @@ -83,7 +83,7 @@ tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors // Generic overloads with differing arity called with type argument count that doesn't match any overload new fn3(); // Error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1-3 type arguments, but got 4. // Generic overloads with constraints called with type arguments that satisfy the constraints interface fn4 { diff --git a/tests/baselines/reference/overloadResolutionOnDefaultConstructor1.errors.txt b/tests/baselines/reference/overloadResolutionOnDefaultConstructor1.errors.txt index 1922df6852a..bdbc2310fb1 100644 --- a/tests/baselines/reference/overloadResolutionOnDefaultConstructor1.errors.txt +++ b/tests/baselines/reference/overloadResolutionOnDefaultConstructor1.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/overloadResolutionOnDefaultConstructor1.ts(3,16): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/overloadResolutionOnDefaultConstructor1.ts(3,16): error TS2554: Expected 0 arguments, but got 1. ==== tests/cases/compiler/overloadResolutionOnDefaultConstructor1.ts (1 errors) ==== @@ -6,6 +6,6 @@ tests/cases/compiler/overloadResolutionOnDefaultConstructor1.ts(3,16): error TS2 public clone() { return new Bar(0); ~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. } } \ No newline at end of file diff --git a/tests/baselines/reference/overloadsAndTypeArgumentArityErrors.errors.txt b/tests/baselines/reference/overloadsAndTypeArgumentArityErrors.errors.txt index 64faaf7e8c1..52bcaaf790b 100644 --- a/tests/baselines/reference/overloadsAndTypeArgumentArityErrors.errors.txt +++ b/tests/baselines/reference/overloadsAndTypeArgumentArityErrors.errors.txt @@ -1,6 +1,6 @@ -tests/cases/compiler/overloadsAndTypeArgumentArityErrors.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/overloadsAndTypeArgumentArityErrors.ts(6,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/overloadsAndTypeArgumentArityErrors.ts(5,1): error TS2558: Expected 0-2 type arguments, but got 3. tests/cases/compiler/overloadsAndTypeArgumentArityErrors.ts(6,1): error TS2350: Only a void function can be called with the 'new' keyword. +tests/cases/compiler/overloadsAndTypeArgumentArityErrors.ts(6,1): error TS2558: Expected 0-2 type arguments, but got 3. ==== tests/cases/compiler/overloadsAndTypeArgumentArityErrors.ts (3 errors) ==== @@ -10,9 +10,9 @@ tests/cases/compiler/overloadsAndTypeArgumentArityErrors.ts(6,1): error TS2350: Callbacks('s'); // wrong number of type arguments ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0-2 type arguments, but got 3. new Callbacks('s'); // wrong number of type arguments ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2350: Only a void function can be called with the 'new' keyword. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2350: Only a void function can be called with the 'new' keyword. \ No newline at end of file +!!! error TS2558: Expected 0-2 type arguments, but got 3. \ No newline at end of file diff --git a/tests/baselines/reference/parserConstructorAmbiguity3.errors.txt b/tests/baselines/reference/parserConstructorAmbiguity3.errors.txt index 821451c00c8..c13916fa39d 100644 --- a/tests/baselines/reference/parserConstructorAmbiguity3.errors.txt +++ b/tests/baselines/reference/parserConstructorAmbiguity3.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/parser/ecmascript5/Generics/parserConstructorAmbiguity3.ts(1,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/parser/ecmascript5/Generics/parserConstructorAmbiguity3.ts(1,1): error TS2558: Expected 0 type arguments, but got 1. tests/cases/conformance/parser/ecmascript5/Generics/parserConstructorAmbiguity3.ts(1,10): error TS2304: Cannot find name 'A'. tests/cases/conformance/parser/ecmascript5/Generics/parserConstructorAmbiguity3.ts(1,12): error TS1005: '(' expected. @@ -6,7 +6,7 @@ tests/cases/conformance/parser/ecmascript5/Generics/parserConstructorAmbiguity3. ==== tests/cases/conformance/parser/ecmascript5/Generics/parserConstructorAmbiguity3.ts (3 errors) ==== new Date ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. ~ !!! error TS2304: Cannot find name 'A'. diff --git a/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.errors.txt b/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.errors.txt index 7fc9396ac28..36bd5b08e19 100644 --- a/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.errors.txt +++ b/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/parser/ecmascript5/parserNoASIOnCallAfterFunctionExpression1.ts(1,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/parser/ecmascript5/parserNoASIOnCallAfterFunctionExpression1.ts(1,9): error TS2554: Expected 0 arguments, but got 1. tests/cases/conformance/parser/ecmascript5/parserNoASIOnCallAfterFunctionExpression1.ts(2,7): error TS2304: Cannot find name 'window'. @@ -7,7 +7,7 @@ tests/cases/conformance/parser/ecmascript5/parserNoASIOnCallAfterFunctionExpress ~~~~~~~~~~~~~~~ (window).foo; ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0 arguments, but got 1. ~~~~~~ !!! error TS2304: Cannot find name 'window'. \ No newline at end of file diff --git a/tests/baselines/reference/recursiveFunctionTypes.errors.txt b/tests/baselines/reference/recursiveFunctionTypes.errors.txt index 8a454133a82..77010d7efa1 100644 --- a/tests/baselines/reference/recursiveFunctionTypes.errors.txt +++ b/tests/baselines/reference/recursiveFunctionTypes.errors.txt @@ -8,9 +8,9 @@ tests/cases/compiler/recursiveFunctionTypes.ts(17,5): error TS2322: Type '() => tests/cases/compiler/recursiveFunctionTypes.ts(22,5): error TS2345: Argument of type '3' is not assignable to parameter of type '(t: typeof g) => void'. tests/cases/compiler/recursiveFunctionTypes.ts(25,1): error TS2322: Type '3' is not assignable to type '() => any'. tests/cases/compiler/recursiveFunctionTypes.ts(30,10): error TS2394: Overload signature is not compatible with function implementation. -tests/cases/compiler/recursiveFunctionTypes.ts(33,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/recursiveFunctionTypes.ts(33,1): error TS2554: Expected 0-1 arguments, but got 2. tests/cases/compiler/recursiveFunctionTypes.ts(34,4): error TS2345: Argument of type '""' is not assignable to parameter of type '{ (): typeof f6; (a: typeof f6): () => number; }'. -tests/cases/compiler/recursiveFunctionTypes.ts(42,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/recursiveFunctionTypes.ts(42,1): error TS2554: Expected 0-1 arguments, but got 2. tests/cases/compiler/recursiveFunctionTypes.ts(43,4): error TS2345: Argument of type '""' is not assignable to parameter of type '{ (): typeof f7; (a: typeof f7): () => number; (a: number): number; (a?: typeof f7): typeof f7; }'. @@ -68,7 +68,7 @@ tests/cases/compiler/recursiveFunctionTypes.ts(43,4): error TS2345: Argument of f6("", 3); // error (arity mismatch) ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-1 arguments, but got 2. f6(""); // ok (function takes an any param) ~~ !!! error TS2345: Argument of type '""' is not assignable to parameter of type '{ (): typeof f6; (a: typeof f6): () => number; }'. @@ -81,7 +81,7 @@ tests/cases/compiler/recursiveFunctionTypes.ts(43,4): error TS2345: Argument of f7("", 3); // error (arity mismatch) ~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 0-1 arguments, but got 2. f7(""); // ok (function takes an any param) ~~ !!! error TS2345: Argument of type '""' is not assignable to parameter of type '{ (): typeof f7; (a: typeof f7): () => number; (a: number): number; (a?: typeof f7): typeof f7; }'. diff --git a/tests/baselines/reference/requiredInitializedParameter1.errors.txt b/tests/baselines/reference/requiredInitializedParameter1.errors.txt index ef958dbdec9..31c0f70ee8d 100644 --- a/tests/baselines/reference/requiredInitializedParameter1.errors.txt +++ b/tests/baselines/reference/requiredInitializedParameter1.errors.txt @@ -1,5 +1,5 @@ -tests/cases/compiler/requiredInitializedParameter1.ts(11,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/requiredInitializedParameter1.ts(16,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/requiredInitializedParameter1.ts(11,1): error TS2554: Expected 3 arguments, but got 2. +tests/cases/compiler/requiredInitializedParameter1.ts(16,1): error TS2554: Expected 3 arguments, but got 1. ==== tests/cases/compiler/requiredInitializedParameter1.ts (2 errors) ==== @@ -15,14 +15,14 @@ tests/cases/compiler/requiredInitializedParameter1.ts(16,1): error TS2346: Suppl f1(0, 1); ~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 3 arguments, but got 2. f2(0, 1); f3(0, 1); f4(0, 1); f1(0); ~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 3 arguments, but got 1. f2(0); f3(0); f4(0); \ No newline at end of file diff --git a/tests/baselines/reference/restParamsWithNonRestParams.errors.txt b/tests/baselines/reference/restParamsWithNonRestParams.errors.txt index 4fdb98206c7..cccbba2f4b5 100644 --- a/tests/baselines/reference/restParamsWithNonRestParams.errors.txt +++ b/tests/baselines/reference/restParamsWithNonRestParams.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/restParamsWithNonRestParams.ts(4,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/restParamsWithNonRestParams.ts(4,1): error TS2555: Expected at least 1 arguments, but got 0. ==== tests/cases/compiler/restParamsWithNonRestParams.ts (1 errors) ==== @@ -7,6 +7,6 @@ tests/cases/compiler/restParamsWithNonRestParams.ts(4,1): error TS2346: Supplied function foo2(a:string, ...b:number[]){} foo2(); // should be an error ~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2555: Expected at least 1 arguments, but got 0. function foo3(a?:string, ...b:number[]){} foo3(); // error but shouldn't be \ No newline at end of file diff --git a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1.errors.txt b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1.errors.txt index e9c9e0ed6e0..109312d6264 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1.errors.txt +++ b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1.errors.txt @@ -4,9 +4,9 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(11,13): error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(12,13): error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(13,13): error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. -tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(14,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(14,9): error TS2554: Expected 1-3 arguments, but got 4. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(19,20): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. -tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(21,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts(21,9): error TS2554: Expected 1-3 arguments, but got 4. ==== tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts (8 errors) ==== @@ -36,7 +36,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio !!! error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. var f = foo([], 1, 2, 3); // any (with error) ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 4. var u = foo ``; // number var v = foo `${1}`; // string @@ -47,5 +47,5 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio var y = foo `${1}${"2"}`; // {} var z = foo `${1}${2}${3}`; // any (with error) ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 4. \ No newline at end of file diff --git a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1_ES6.errors.txt b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1_ES6.errors.txt index d7817e32ee0..0d2cafea7b3 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1_ES6.errors.txt +++ b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution1_ES6.errors.txt @@ -4,9 +4,9 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(11,13): error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(12,13): error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(13,13): error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. -tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(14,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(14,9): error TS2554: Expected 1-3 arguments, but got 4. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(19,20): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. -tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(21,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts(21,9): error TS2554: Expected 1-3 arguments, but got 4. ==== tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts (8 errors) ==== @@ -36,7 +36,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio !!! error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'. var f = foo([], 1, 2, 3); // any (with error) ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 4. var u = foo ``; // number var v = foo `${1}`; // string @@ -47,5 +47,5 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio var y = foo `${1}${"2"}`; // {} var z = foo `${1}${2}${3}`; // any (with error) ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-3 arguments, but got 4. \ No newline at end of file diff --git a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.errors.txt b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.errors.txt index 444985cb380..e7fb6ea1241 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.errors.txt +++ b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.errors.txt @@ -1,6 +1,6 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3.ts(9,9): error TS2345: Argument of type '{}' is not assignable to parameter of type 'number'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3.ts(18,4): error TS2339: Property 'foo' does not exist on type 'Date'. -tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3.ts(44,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3.ts(44,1): error TS2554: Expected 2-4 arguments, but got 1. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3.ts(62,9): error TS2345: Argument of type 'true' is not assignable to parameter of type 'number'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3.ts(63,18): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3.ts(69,18): error TS2339: Property 'toFixed' does not exist on type 'string'. @@ -56,7 +56,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio // Generic overloads with differing arity tagging with argument count that doesn't match any overload fn3 ``; // Error ~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2-4 arguments, but got 1. // Generic overloads with constraints function fn4(strs: TemplateStringsArray, n: T, m: U); diff --git a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.errors.txt b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.errors.txt index 7329ade1b64..d41d64c5a28 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.errors.txt +++ b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.errors.txt @@ -1,6 +1,6 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3_ES6.ts(9,9): error TS2345: Argument of type '{}' is not assignable to parameter of type 'number'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3_ES6.ts(18,4): error TS2339: Property 'foo' does not exist on type 'Date'. -tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3_ES6.ts(44,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3_ES6.ts(44,1): error TS2554: Expected 2-4 arguments, but got 1. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3_ES6.ts(62,9): error TS2345: Argument of type 'true' is not assignable to parameter of type 'number'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3_ES6.ts(63,18): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution3_ES6.ts(69,18): error TS2339: Property 'toFixed' does not exist on type 'string'. @@ -56,7 +56,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio // Generic overloads with differing arity tagging with argument count that doesn't match any overload fn3 ``; // Error ~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2-4 arguments, but got 1. // Generic overloads with constraints function fn4(strs: TemplateStringsArray, n: T, m: U); diff --git a/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions4.errors.txt b/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions4.errors.txt index cc499cb2578..71066aec61f 100644 --- a/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions4.errors.txt +++ b/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions4.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions4.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions4.ts(5,1): error TS2554: Expected 3 arguments, but got 4. tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions4.ts(5,24): error TS1109: Expression expected. tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions4.ts(5,28): error TS1109: Expression expected. @@ -10,7 +10,7 @@ tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions4.ts(5,28): // Incomplete call, but too many parameters. f `123qdawdrqw${ 1 }${ }${ ~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 3 arguments, but got 4. ~ !!! error TS1109: Expression expected. diff --git a/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions5.errors.txt b/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions5.errors.txt index 0a4f0724cc2..e18bafa9149 100644 --- a/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions5.errors.txt +++ b/tests/baselines/reference/taggedTemplatesWithIncompleteTemplateExpressions5.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions5.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions5.ts(5,1): error TS2554: Expected 3 arguments, but got 4. tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions5.ts(5,30): error TS1109: Expression expected. @@ -9,6 +9,6 @@ tests/cases/compiler/taggedTemplatesWithIncompleteTemplateExpressions5.ts(5,30): // Incomplete call, but too many parameters. f `123qdawdrqw${ 1 }${ 2 }${ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 3 arguments, but got 4. !!! error TS1109: Expression expected. \ No newline at end of file diff --git a/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.errors.txt b/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.errors.txt index 6f60a8f1be7..5288875b0ce 100644 --- a/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.errors.txt +++ b/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.errors.txt @@ -1,10 +1,10 @@ -tests/cases/compiler/thisExpressionInCallExpressionWithTypeArguments.ts(2,20): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/thisExpressionInCallExpressionWithTypeArguments.ts(2,20): error TS2554: Expected 1-2 arguments, but got 1. ==== tests/cases/compiler/thisExpressionInCallExpressionWithTypeArguments.ts (1 errors) ==== class C { public foo() { [1,2,3].map((x) => { return this; })} ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 1. } \ No newline at end of file diff --git a/tests/baselines/reference/thisTypeInFunctionsNegative.errors.txt b/tests/baselines/reference/thisTypeInFunctionsNegative.errors.txt index a3771839dc5..ad8978847f4 100644 --- a/tests/baselines/reference/thisTypeInFunctionsNegative.errors.txt +++ b/tests/baselines/reference/thisTypeInFunctionsNegative.errors.txt @@ -10,26 +10,26 @@ tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(62,97): er Object literal may only specify known properties, and 'explicitStructural' does not exist in type '{ y: string; f: (this: { y: number; }, x: number) => number; }'. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(63,110): error TS2322: Type '{ wrongName: number; explicitStructural: (this: { y: number; }, x: number) => number; }' is not assignable to type '{ wrongName: number; f: (this: { y: number; }, x: number) => number; }'. Object literal may only specify known properties, and 'explicitStructural' does not exist in type '{ wrongName: number; f: (this: { y: number; }, x: number) => number; }'. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(65,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(65,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(66,6): error TS2345: Argument of type '"wrong type"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(67,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(67,1): error TS2554: Expected 1 arguments, but got 2. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(68,1): error TS2684: The 'this' context of type '{ y: string; f: (this: { y: number; }, x: number) => number; }' is not assignable to method's 'this' of type '{ y: number; }'. Types of property 'y' are incompatible. Type 'string' is not assignable to type 'number'. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(69,1): error TS2684: The 'this' context of type '{ wrongName: number; f: (this: { y: number; }, x: number) => number; }' is not assignable to method's 'this' of type '{ y: number; }'. Property 'y' is missing in type '{ wrongName: number; f: (this: { y: number; }, x: number) => number; }'. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(72,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(72,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(73,13): error TS2345: Argument of type '"wrong type"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(74,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(75,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(74,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(75,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(76,16): error TS2345: Argument of type '"wrong type 2"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(77,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(78,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(77,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(78,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(79,16): error TS2345: Argument of type '"wrong type 2"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(80,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(81,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(80,1): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(81,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(82,20): error TS2345: Argument of type '"wrong type 3"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(83,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(83,1): error TS2554: Expected 1 arguments, but got 2. tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(86,5): error TS2322: Type '(this: { y: number; }, x: number) => number' is not assignable to type '(this: void, x: number) => number'. The 'this' types of each signature are incompatible. Type 'void' is not assignable to type '{ y: number; }'. @@ -187,13 +187,13 @@ tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(175,35): e ok.f(); // not enough arguments ~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. ok.f('wrong type'); ~~~~~~~~~~~~ !!! error TS2345: Argument of type '"wrong type"' is not assignable to parameter of type 'number'. ok.f(13, 'too many arguments'); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. wrongPropertyType.f(13); ~~~~~~~~~~~~~~~~~ !!! error TS2684: The 'this' context of type '{ y: string; f: (this: { y: number; }, x: number) => number; }' is not assignable to method's 'this' of type '{ y: number; }'. @@ -207,40 +207,40 @@ tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(175,35): e let c = new C(); c.explicitC(); // not enough arguments ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. c.explicitC('wrong type'); ~~~~~~~~~~~~ !!! error TS2345: Argument of type '"wrong type"' is not assignable to parameter of type 'number'. c.explicitC(13, 'too many arguments'); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. c.explicitThis(); // not enough arguments ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. c.explicitThis('wrong type 2'); ~~~~~~~~~~~~~~ !!! error TS2345: Argument of type '"wrong type 2"' is not assignable to parameter of type 'number'. c.explicitThis(14, 'too many arguments 2'); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. c.implicitThis(); // not enough arguments ~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. c.implicitThis('wrong type 2'); ~~~~~~~~~~~~~~ !!! error TS2345: Argument of type '"wrong type 2"' is not assignable to parameter of type 'number'. c.implicitThis(14, 'too many arguments 2'); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. c.explicitProperty(); // not enough arguments ~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. c.explicitProperty('wrong type 3'); ~~~~~~~~~~~~~~ !!! error TS2345: Argument of type '"wrong type 3"' is not assignable to parameter of type 'number'. c.explicitProperty(15, 'too many arguments 3'); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. // oops, this triggers contextual typing, which needs to be updated to understand that =>'s `this` is void. let specifiedToVoid: (this: void, x: number) => number = explicitStructural; diff --git a/tests/baselines/reference/tooManyTypeParameters1.errors.txt b/tests/baselines/reference/tooManyTypeParameters1.errors.txt index 2355ef55e56..7997e68b575 100644 --- a/tests/baselines/reference/tooManyTypeParameters1.errors.txt +++ b/tests/baselines/reference/tooManyTypeParameters1.errors.txt @@ -1,6 +1,6 @@ -tests/cases/compiler/tooManyTypeParameters1.ts(2,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/tooManyTypeParameters1.ts(5,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/tooManyTypeParameters1.ts(8,9): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/tooManyTypeParameters1.ts(2,1): error TS2558: Expected 1 type arguments, but got 2. +tests/cases/compiler/tooManyTypeParameters1.ts(5,1): error TS2558: Expected 1 type arguments, but got 2. +tests/cases/compiler/tooManyTypeParameters1.ts(8,9): error TS2558: Expected 1 type arguments, but got 2. tests/cases/compiler/tooManyTypeParameters1.ts(11,8): error TS2314: Generic type 'I' requires 1 type argument(s). @@ -8,17 +8,17 @@ tests/cases/compiler/tooManyTypeParameters1.ts(11,8): error TS2314: Generic type function f() { } f(); ~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1 type arguments, but got 2. var x = () => {}; x(); ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1 type arguments, but got 2. class C {} var c = new C(); ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 1 type arguments, but got 2. interface I {} var i: I; diff --git a/tests/baselines/reference/typeArgumentsOnFunctionsWithNoTypeParameters.errors.txt b/tests/baselines/reference/typeArgumentsOnFunctionsWithNoTypeParameters.errors.txt index b2d9e3f8aaf..5c916331950 100644 --- a/tests/baselines/reference/typeArgumentsOnFunctionsWithNoTypeParameters.errors.txt +++ b/tests/baselines/reference/typeArgumentsOnFunctionsWithNoTypeParameters.errors.txt @@ -1,19 +1,19 @@ -tests/cases/compiler/typeArgumentsOnFunctionsWithNoTypeParameters.ts(2,13): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/typeArgumentsOnFunctionsWithNoTypeParameters.ts(2,13): error TS2558: Expected 0 type arguments, but got 1. tests/cases/compiler/typeArgumentsOnFunctionsWithNoTypeParameters.ts(3,15): error TS2345: Argument of type '1' is not assignable to parameter of type 'T'. -tests/cases/compiler/typeArgumentsOnFunctionsWithNoTypeParameters.ts(4,13): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/typeArgumentsOnFunctionsWithNoTypeParameters.ts(4,13): error TS2558: Expected 0 type arguments, but got 1. ==== tests/cases/compiler/typeArgumentsOnFunctionsWithNoTypeParameters.ts (3 errors) ==== function foo(f: (v: T) => U) { var r1 = f(1); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r2 = f(1); ~ !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'T'. var r3 = f(null); ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var r4 = f(null); } \ No newline at end of file diff --git a/tests/baselines/reference/typeAssertionToGenericFunctionType.errors.txt b/tests/baselines/reference/typeAssertionToGenericFunctionType.errors.txt index 7d99934f5ea..0df5d91865d 100644 --- a/tests/baselines/reference/typeAssertionToGenericFunctionType.errors.txt +++ b/tests/baselines/reference/typeAssertionToGenericFunctionType.errors.txt @@ -1,5 +1,5 @@ tests/cases/compiler/typeAssertionToGenericFunctionType.ts(5,13): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. -tests/cases/compiler/typeAssertionToGenericFunctionType.ts(6,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/typeAssertionToGenericFunctionType.ts(6,1): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/compiler/typeAssertionToGenericFunctionType.ts (2 errors) ==== @@ -12,4 +12,4 @@ tests/cases/compiler/typeAssertionToGenericFunctionType.ts(6,1): error TS2346: S !!! error TS2345: Argument of type '1' is not assignable to parameter of type 'string'. x.b(); // error ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/typeAssertions.errors.txt b/tests/baselines/reference/typeAssertions.errors.txt index cdd576e6d8b..45f20437860 100644 --- a/tests/baselines/reference/typeAssertions.errors.txt +++ b/tests/baselines/reference/typeAssertions.errors.txt @@ -1,4 +1,4 @@ -tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(5,5): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(5,5): error TS2558: Expected 0 type arguments, but got 1. tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(31,12): error TS2352: Type 'SomeOther' cannot be converted to type 'SomeBase'. Property 'p' is missing in type 'SomeOther'. tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(35,15): error TS2352: Type 'SomeOther' cannot be converted to type 'SomeDerived'. @@ -30,7 +30,7 @@ tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,50): err fn1(fn2(4)); // Error ~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var a: any; var s: string; diff --git a/tests/baselines/reference/typesWithPublicConstructor.errors.txt b/tests/baselines/reference/typesWithPublicConstructor.errors.txt index 17abc57f6df..d3b03740bf2 100644 --- a/tests/baselines/reference/typesWithPublicConstructor.errors.txt +++ b/tests/baselines/reference/typesWithPublicConstructor.errors.txt @@ -1,6 +1,6 @@ tests/cases/conformance/types/members/typesWithPublicConstructor.ts(8,5): error TS2322: Type 'Function' is not assignable to type '() => void'. Type 'Function' provides no match for the signature '(): void'. -tests/cases/conformance/types/members/typesWithPublicConstructor.ts(15,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/members/typesWithPublicConstructor.ts(15,10): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/conformance/types/members/typesWithPublicConstructor.ts (2 errors) ==== @@ -23,5 +23,5 @@ tests/cases/conformance/types/members/typesWithPublicConstructor.ts(15,10): erro var c2 = new C2(); ~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var r2: (x: number) => void = c2.constructor; \ No newline at end of file diff --git a/tests/baselines/reference/unionTypeCallSignatures.errors.txt b/tests/baselines/reference/unionTypeCallSignatures.errors.txt index 0398c0cec47..c123dc8da56 100644 --- a/tests/baselines/reference/unionTypeCallSignatures.errors.txt +++ b/tests/baselines/reference/unionTypeCallSignatures.errors.txt @@ -1,34 +1,34 @@ tests/cases/conformance/types/union/unionTypeCallSignatures.ts(9,43): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(10,29): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(15,29): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(16,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(16,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(19,1): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type '((a: number) => number) | ((a: string) => Date)' has no compatible call signatures. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(20,1): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type '((a: number) => number) | ((a: string) => Date)' has no compatible call signatures. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(21,1): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type '((a: number) => number) | ((a: string) => Date)' has no compatible call signatures. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(24,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(24,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(26,36): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(29,1): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type '((a: string) => string) | ((a: string, b: number) => number)' has no compatible call signatures. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(30,1): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type '((a: string) => string) | ((a: string, b: number) => number)' has no compatible call signatures. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(31,1): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type '((a: string) => string) | ((a: string, b: number) => number)' has no compatible call signatures. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(36,49): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(37,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(40,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(37,12): error TS2554: Expected 1-2 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(40,12): error TS2554: Expected 2 arguments, but got 1. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(42,49): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(43,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(47,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(48,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(49,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(43,12): error TS2554: Expected 2 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(47,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(48,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(49,12): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(55,45): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(56,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(59,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(61,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(56,12): error TS2555: Expected at least 1 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(59,12): error TS2554: Expected 2 arguments, but got 1. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(61,12): error TS2554: Expected 2 arguments, but got 3. tests/cases/conformance/types/union/unionTypeCallSignatures.ts(62,45): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(63,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(67,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(68,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(69,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(70,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures.ts(73,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(63,12): error TS2554: Expected 2 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(67,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(68,12): error TS2554: Expected 1 arguments, but got 3. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(69,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(70,12): error TS2554: Expected 1 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeCallSignatures.ts(73,12): error TS2554: Expected 2 arguments, but got 1. ==== tests/cases/conformance/types/union/unionTypeCallSignatures.ts (31 errors) ==== @@ -55,7 +55,7 @@ tests/cases/conformance/types/union/unionTypeCallSignatures.ts(73,12): error TS2 !!! error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. unionOfDifferentReturnType1(); // error missing parameter ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var unionOfDifferentParameterTypes: { (a: number): number; } | { (a: string): Date; }; unionOfDifferentParameterTypes(10);// error - no call signatures @@ -71,7 +71,7 @@ tests/cases/conformance/types/union/unionTypeCallSignatures.ts(73,12): error TS2 var unionOfDifferentNumberOfSignatures: { (a: number): number; } | { (a: number): Date; (a: string): boolean; }; unionOfDifferentNumberOfSignatures(); // error - no call signatures ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. unionOfDifferentNumberOfSignatures(10); // error - no call signatures unionOfDifferentNumberOfSignatures("hello"); // error - no call signatures ~~~~~~~ @@ -96,31 +96,31 @@ tests/cases/conformance/types/union/unionTypeCallSignatures.ts(73,12): error TS2 !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = unionWithOptionalParameter1(); // error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. var unionWithOptionalParameter2: { (a: string, b?: number): string; } | { (a: string, b: number): number }; strOrNum = unionWithOptionalParameter2('hello'); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. strOrNum = unionWithOptionalParameter2('hello', 10); // error no call signature strOrNum = unionWithOptionalParameter2('hello', "hello"); // error no call signature ~~~~~~~ !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = unionWithOptionalParameter2(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 0. var unionWithOptionalParameter3: { (a: string, b?: number): string; } | { (a: string): number; }; strOrNum = unionWithOptionalParameter3('hello'); strOrNum = unionWithOptionalParameter3('hello', 10); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = unionWithOptionalParameter3('hello', "hello"); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = unionWithOptionalParameter3(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var unionWithRestParameter1: { (a: string, ...b: number[]): string; } | { (a: string, ...b: number[]): number }; strOrNum = unionWithRestParameter1('hello'); @@ -131,41 +131,41 @@ tests/cases/conformance/types/union/unionTypeCallSignatures.ts(73,12): error TS2 !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = unionWithRestParameter1(); // error ~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2555: Expected at least 1 arguments, but got 0. var unionWithRestParameter2: { (a: string, ...b: number[]): string; } | { (a: string, b: number): number }; strOrNum = unionWithRestParameter2('hello'); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. strOrNum = unionWithRestParameter2('hello', 10); // error no call signature strOrNum = unionWithRestParameter2('hello', 10, 11); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 3. strOrNum = unionWithRestParameter2('hello', "hello"); // error no call signature ~~~~~~~ !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = unionWithRestParameter2(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 0. var unionWithRestParameter3: { (a: string, ...b: number[]): string; } | { (a: string): number }; strOrNum = unionWithRestParameter3('hello'); strOrNum = unionWithRestParameter3('hello', 10); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = unionWithRestParameter3('hello', 10, 11); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 3. strOrNum = unionWithRestParameter3('hello', "hello"); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = unionWithRestParameter3(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var unionWithRestParameter4: { (...a: string[]): string; } | { (a: string, b: string): number; }; strOrNum = unionWithRestParameter4("hello"); // error supplied parameters do not match any call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. strOrNum = unionWithRestParameter4("hello", "world"); \ No newline at end of file diff --git a/tests/baselines/reference/unionTypeCallSignatures4.errors.txt b/tests/baselines/reference/unionTypeCallSignatures4.errors.txt index 585906a6b5a..1d9c3d272f0 100644 --- a/tests/baselines/reference/unionTypeCallSignatures4.errors.txt +++ b/tests/baselines/reference/unionTypeCallSignatures4.errors.txt @@ -1,7 +1,7 @@ -tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(10,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(20,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(23,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(25,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(10,1): error TS2554: Expected 1-2 arguments, but got 3. +tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(20,1): error TS2554: Expected 1-2 arguments, but got 3. +tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(23,1): error TS2554: Expected 2 arguments, but got 1. +tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(25,1): error TS2554: Expected 2 arguments, but got 3. ==== tests/cases/conformance/types/union/unionTypeCallSignatures4.ts (4 errors) ==== @@ -16,7 +16,7 @@ tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(25,1): error TS2 f12("a", "b"); f12("a", "b", "c"); // error ~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 3. var f34: F3 | F4; f34("a"); @@ -28,14 +28,14 @@ tests/cases/conformance/types/union/unionTypeCallSignatures4.ts(25,1): error TS2 f1234("a", "b"); f1234("a", "b", "c"); // error ~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 3. var f12345: F1 | F2 | F3 | F4 | F5; f12345("a"); // error ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. f12345("a", "b"); f12345("a", "b", "c"); // error ~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 3. \ No newline at end of file diff --git a/tests/baselines/reference/unionTypeConstructSignatures.errors.txt b/tests/baselines/reference/unionTypeConstructSignatures.errors.txt index 813f7701ea8..8b4c6f9aa0c 100644 --- a/tests/baselines/reference/unionTypeConstructSignatures.errors.txt +++ b/tests/baselines/reference/unionTypeConstructSignatures.errors.txt @@ -1,33 +1,33 @@ tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(9,47): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(10,33): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(15,33): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(16,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(16,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(19,1): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(20,1): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(21,1): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(24,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(24,1): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(26,40): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(29,1): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(30,1): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(31,1): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(36,53): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(37,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(40,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(37,12): error TS2554: Expected 1-2 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(40,12): error TS2554: Expected 2 arguments, but got 1. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(42,53): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(43,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(47,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(48,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(49,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(43,12): error TS2554: Expected 2 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(47,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(48,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(49,12): error TS2554: Expected 1 arguments, but got 0. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(55,49): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(56,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(59,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(61,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(56,12): error TS2555: Expected at least 1 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(59,12): error TS2554: Expected 2 arguments, but got 1. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(61,12): error TS2554: Expected 2 arguments, but got 3. tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(62,49): error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(63,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(67,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(68,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(69,12): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(70,12): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(63,12): error TS2554: Expected 2 arguments, but got 0. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(67,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(68,12): error TS2554: Expected 1 arguments, but got 3. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(69,12): error TS2554: Expected 1 arguments, but got 2. +tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(70,12): error TS2554: Expected 1 arguments, but got 0. ==== tests/cases/conformance/types/union/unionTypeConstructSignatures.ts (30 errors) ==== @@ -54,7 +54,7 @@ tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(70,12): erro !!! error TS2345: Argument of type 'true' is not assignable to parameter of type 'string'. new unionOfDifferentReturnType1(); // error missing parameter ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var unionOfDifferentParameterTypes: { new (a: number): number; } | { new (a: string): Date; }; new unionOfDifferentParameterTypes(10);// error - no call signatures @@ -70,7 +70,7 @@ tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(70,12): erro var unionOfDifferentNumberOfSignatures: { new (a: number): number; } | { new (a: number): Date; new (a: string): boolean; }; new unionOfDifferentNumberOfSignatures(); // error - no call signatures ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. new unionOfDifferentNumberOfSignatures(10); // error - no call signatures new unionOfDifferentNumberOfSignatures("hello"); // error - no call signatures ~~~~~~~ @@ -95,31 +95,31 @@ tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(70,12): erro !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = new unionWithOptionalParameter1(); // error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1-2 arguments, but got 0. var unionWithOptionalParameter2: { new (a: string, b?: number): string; } | { new (a: string, b: number): number }; strOrNum = new unionWithOptionalParameter2('hello'); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. strOrNum = new unionWithOptionalParameter2('hello', 10); // error no call signature strOrNum = new unionWithOptionalParameter2('hello', "hello"); // error no call signature ~~~~~~~ !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = new unionWithOptionalParameter2(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 0. var unionWithOptionalParameter3: { new (a: string, b?: number): string; } | { new (a: string): number; }; strOrNum = new unionWithOptionalParameter3('hello'); // error no call signature strOrNum = new unionWithOptionalParameter3('hello', 10); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = new unionWithOptionalParameter3('hello', "hello"); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = new unionWithOptionalParameter3(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 0. var unionWithRestParameter1: { new (a: string, ...b: number[]): string; } | { new (a: string, ...b: number[]): number }; strOrNum = new unionWithRestParameter1('hello'); @@ -130,34 +130,34 @@ tests/cases/conformance/types/union/unionTypeConstructSignatures.ts(70,12): erro !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = new unionWithRestParameter1(); // error ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2555: Expected at least 1 arguments, but got 0. var unionWithRestParameter2: { new (a: string, ...b: number[]): string; } | { new (a: string, b: number): number }; strOrNum = new unionWithRestParameter2('hello'); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 1. strOrNum = new unionWithRestParameter2('hello', 10); // error no call signature strOrNum = new unionWithRestParameter2('hello', 10, 11); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 3. strOrNum = new unionWithRestParameter2('hello', "hello"); // error no call signature ~~~~~~~ !!! error TS2345: Argument of type '"hello"' is not assignable to parameter of type 'number'. strOrNum = new unionWithRestParameter2(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 2 arguments, but got 0. var unionWithRestParameter3: { new (a: string, ...b: number[]): string; } | { new (a: string): number }; strOrNum = new unionWithRestParameter3('hello'); // error no call signature strOrNum = new unionWithRestParameter3('hello', 10); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = new unionWithRestParameter3('hello', 10, 11); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 3. strOrNum = new unionWithRestParameter3('hello', "hello"); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2554: Expected 1 arguments, but got 2. strOrNum = new unionWithRestParameter3(); // error no call signature ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. \ No newline at end of file +!!! error TS2554: Expected 1 arguments, but got 0. \ No newline at end of file diff --git a/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.errors.txt b/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.errors.txt index 399a37c32fd..6b6594fc1ed 100644 --- a/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.errors.txt +++ b/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.errors.txt @@ -1,13 +1,13 @@ -tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(3,10): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(3,10): error TS2558: Expected 0 type arguments, but got 1. tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(5,10): error TS2347: Untyped function calls may not accept type arguments. tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(8,10): error TS2347: Untyped function calls may not accept type arguments. tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(10,7): error TS2420: Class 'C' incorrectly implements interface 'Function'. Property 'apply' is missing in type 'C'. tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(18,10): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type 'C' has no compatible call signatures. tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(22,10): error TS2347: Untyped function calls may not accept type arguments. -tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(28,10): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(35,1): error TS2346: Supplied parameters do not match any signature of call target. -tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(41,1): error TS2346: Supplied parameters do not match any signature of call target. +tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(28,10): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(35,1): error TS2558: Expected 0 type arguments, but got 1. +tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(41,1): error TS2558: Expected 0 type arguments, but got 1. ==== tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts (9 errors) ==== @@ -15,7 +15,7 @@ tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(41,1): error TS2 var x = function () { return; }; var r1 = x(); ~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. var y: any = x; var r2 = y(); ~~~~~~~~~~~ @@ -53,7 +53,7 @@ tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(41,1): error TS2 var z: I; var r6 = z(1); // error ~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. interface callable2 { (a: T): T; @@ -62,7 +62,7 @@ tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(41,1): error TS2 var c4: callable2; c4(1); ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. interface callable3 { (a: T): T; } @@ -70,6 +70,6 @@ tests/cases/compiler/untypedFunctionCallsWithTypeParameters1.ts(41,1): error TS2 var c5: callable3; c5(1); // error ~~~~~~~~~~~~~ -!!! error TS2346: Supplied parameters do not match any signature of call target. +!!! error TS2558: Expected 0 type arguments, but got 1. \ No newline at end of file