|
1 |
| -tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(26,18): error TS2345: Argument of type '(a: number) => string' is not assignable to parameter of type '(a: number) => number'. |
2 |
| - Type 'string' is not assignable to type 'number'. |
3 |
| -tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(30,15): error TS2346: Supplied parameters do not match any signature of call target. |
4 |
| -tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(33,15): error TS2346: Supplied parameters do not match any signature of call target. |
5 |
| -tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(34,16): error TS2346: Supplied parameters do not match any signature of call target. |
6 |
| -tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(35,23): error TS2345: Argument of type '(a: number) => string' is not assignable to parameter of type '(a: number) => number'. |
7 |
| - Type 'string' is not assignable to type 'number'. |
| 1 | +tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(26,10): error TS2453: The type argument for type parameter 'U' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 2 | + Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'string'. |
| 3 | +tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(30,15): error TS2453: The type argument for type parameter 'T' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 4 | + Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'T'. |
| 5 | +tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(33,15): error TS2453: The type argument for type parameter 'T' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 6 | + Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'T'. |
| 7 | +tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(34,16): error TS2453: The type argument for type parameter 'T' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 8 | + Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'T'. |
| 9 | +tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(35,15): error TS2453: The type argument for type parameter 'U' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 10 | + Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'string'. |
8 | 11 |
|
9 | 12 |
|
10 | 13 | ==== tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts (5 errors) ====
|
@@ -34,25 +37,28 @@ tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFun
|
34 | 37 | var r7 = foo3(1, <Z>(a: Z) => '', ''); // string
|
35 | 38 |
|
36 | 39 | var r8 = foo3(1, function (a) { return '' }, 1); // error
|
37 |
| - ~~~~~~~~~~~~~~~~~~~~~~~~~~ |
38 |
| -!!! error TS2345: Argument of type '(a: number) => string' is not assignable to parameter of type '(a: number) => number'. |
39 |
| -!!! error TS2345: Type 'string' is not assignable to type 'number'. |
| 40 | + ~~~~ |
| 41 | +!!! error TS2453: The type argument for type parameter 'U' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 42 | +!!! error TS2453: Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'string'. |
40 | 43 | var r9 = foo3<number, string>(1, (a) => '', ''); // string
|
41 | 44 |
|
42 | 45 | function other<T, U>(t: T, u: U) {
|
43 | 46 | var r10 = foo2(1, (x: T) => ''); // error
|
44 |
| - ~~~~~~~~~~~~~~~~~~~~~ |
45 |
| -!!! error TS2346: Supplied parameters do not match any signature of call target. |
| 47 | + ~~~~ |
| 48 | +!!! error TS2453: The type argument for type parameter 'T' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 49 | +!!! error TS2453: Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'T'. |
46 | 50 | var r10 = foo2(1, (x) => ''); // string
|
47 | 51 |
|
48 | 52 | var r11 = foo3(1, (x: T) => '', ''); // error
|
49 |
| - ~~~~~~~~~~~~~~~~~~~~~~~~~ |
50 |
| -!!! error TS2346: Supplied parameters do not match any signature of call target. |
| 53 | + ~~~~ |
| 54 | +!!! error TS2453: The type argument for type parameter 'T' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 55 | +!!! error TS2453: Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'T'. |
51 | 56 | var r11b = foo3(1, (x: T) => '', 1); // error
|
52 |
| - ~~~~~~~~~~~~~~~~~~~~~~~~ |
53 |
| -!!! error TS2346: Supplied parameters do not match any signature of call target. |
| 57 | + ~~~~ |
| 58 | +!!! error TS2453: The type argument for type parameter 'T' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 59 | +!!! error TS2453: Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'T'. |
54 | 60 | var r12 = foo3(1, function (a) { return '' }, 1); // error
|
55 |
| - ~~~~~~~~~~~~~~~~~~~~~~~~~~ |
56 |
| -!!! error TS2345: Argument of type '(a: number) => string' is not assignable to parameter of type '(a: number) => number'. |
57 |
| -!!! error TS2345: Type 'string' is not assignable to type 'number'. |
| 61 | + ~~~~ |
| 62 | +!!! error TS2453: The type argument for type parameter 'U' cannot be inferred from the usage. Consider specifying the type arguments explicitly: |
| 63 | +!!! error TS2453: Type argument candidate 'number' is not a valid type argument because it is not a supertype of candidate 'string'. |
58 | 64 | }
|
0 commit comments