You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
!!! error TS2322: Type '{ type: T; localChannelId: string; }' is not assignable to type 'Pick<ChannelOfType<T, TextChannel> | ChannelOfType<T, EmailChannel>, "type">'.
61
61
!!! error TS2322: Types of property 'type' are incompatible.
62
62
!!! error TS2322: Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
63
-
!!! error TS2322: Type 'string' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
64
-
!!! error TS2322: Type 'string' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
65
-
!!! error TS2322: Type 'string' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
63
+
!!! error TS2322: Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
64
+
!!! error TS2322: Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
65
+
!!! error TS2322: Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
66
66
!!! error TS2322: Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
67
-
!!! error TS2322: Type 'string' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
68
-
!!! error TS2322: Type 'string' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
69
-
!!! error TS2322: Type 'string' is not assignable to type 'T & "text"'.
70
-
!!! error TS2322: Type 'string' is not assignable to type 'T'.
67
+
!!! error TS2322: Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
68
+
!!! error TS2322: Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
69
+
!!! error TS2322: Type '"text"' is not assignable to type 'T & "text"'.
70
+
!!! error TS2322: Type '"text"' is not assignable to type 'T'.
71
71
!!! error TS2322: '"text"' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint '"text" | "email"'.
72
72
!!! error TS2322: Type 'T' is not assignable to type 'T & "text"'.
73
-
!!! error TS2322: Type 'string' is not assignable to type 'T & "text"'.
74
-
!!! error TS2322: Type 'string' is not assignable to type 'T & "text"'.
75
-
!!! error TS2322: Type 'string' is not assignable to type 'T'.
73
+
!!! error TS2322: Type '"text" | "email"' is not assignable to type 'T & "text"'.
74
+
!!! error TS2322: Type '"text"' is not assignable to type 'T & "text"'.
75
+
!!! error TS2322: Type '"text"' is not assignable to type 'T'.
76
76
!!! error TS2322: '"text"' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint '"text" | "email"'.
77
77
!!! error TS2322: Type 'T' is not assignable to type '"text"'.
78
78
!!! error TS2322: Type '"text" | "email"' is not assignable to type '"text"'.
!!! error TS2322: 'ZeroOf<T>' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'string | number'.
284
284
!!! error TS2322: Type '0 | (T extends string ? "" : false)' is not assignable to type 'T'.
285
285
!!! error TS2322: 'T' could be instantiated with an arbitrary type which could be unrelated to '0 | (T extends string ? "" : false)'.
286
-
!!! error TS2322: Type 'number' is not assignable to type 'T'.
286
+
!!! error TS2322: Type '0' is not assignable to type 'T'.
287
287
!!! error TS2322: '0' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'string | number'.
288
-
!!! error TS2322: Type 'string | number' is not assignable to type 'T'.
288
+
!!! error TS2322: Type '"" | 0' is not assignable to type 'T'.
289
289
!!! error TS2322: '"" | 0' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'string | number'.
290
-
!!! error TS2322: Type 'string' is not assignable to type 'T'.
290
+
!!! error TS2322: Type '""' is not assignable to type 'T'.
291
291
!!! error TS2322: '""' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'string | number'.
Copy file name to clipboardExpand all lines: tests/baselines/reference/constructorImplementationWithDefaultValues2.errors.txt
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
tests/cases/conformance/classes/constructorDeclarations/constructorParameters/constructorImplementationWithDefaultValues2.ts(3,17): error TS2322: Type 'number' is not assignable to type 'string'.
2
-
tests/cases/conformance/classes/constructorDeclarations/constructorParameters/constructorImplementationWithDefaultValues2.ts(10,17): error TS2322: Type 'number' is not assignable to type 'T'.
2
+
tests/cases/conformance/classes/constructorDeclarations/constructorParameters/constructorImplementationWithDefaultValues2.ts(10,17): error TS2322: Type '1' is not assignable to type 'T'.
3
3
'T' could be instantiated with an arbitrary type which could be unrelated to '1'.
4
4
tests/cases/conformance/classes/constructorDeclarations/constructorParameters/constructorImplementationWithDefaultValues2.ts(10,27): error TS2322: Type 'T' is not assignable to type 'U'.
5
5
'U' could be instantiated with an arbitrary type which could be unrelated to 'T'.
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(11,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
3
3
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(19,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
4
4
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(30,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
5
-
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(30,18): error TS2322: Type 'string' is not assignable to type 'T'.
5
+
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(30,18): error TS2322: Type '""' is not assignable to type 'T'.
6
6
'""' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'string'.
7
-
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(32,9): error TS2322: Type 'string' is not assignable to type 'T'.
7
+
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(32,9): error TS2322: Type '""' is not assignable to type 'T'.
8
8
'""' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'string'.
9
9
tests/cases/conformance/classes/members/inheritanceAndOverriding/derivedGenericClassWithAny.ts(41,1): error TS2322: Type 'E<string>' is not assignable to type 'C<number>'.
tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(30,23): error TS2345: Argument of type '(x: T) => string' is not assignable to parameter of type '(a: 1) => string'.
4
4
Types of parameters 'x' and 'a' are incompatible.
5
-
Type 'number' is not assignable to type 'T'.
5
+
Type '1' is not assignable to type 'T'.
6
6
'T' could be instantiated with an arbitrary type which could be unrelated to '1'.
7
7
tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(33,23): error TS2345: Argument of type '(x: T) => string' is not assignable to parameter of type '(a: 1) => string'.
8
8
Types of parameters 'x' and 'a' are incompatible.
9
-
Type 'number' is not assignable to type 'T'.
9
+
Type '1' is not assignable to type 'T'.
10
10
'T' could be instantiated with an arbitrary type which could be unrelated to '1'.
11
11
tests/cases/conformance/types/typeRelationships/typeInference/genericCallWithFunctionTypedArguments.ts(34,24): error TS2345: Argument of type '(x: T) => string' is not assignable to parameter of type '(a: 1) => string'.
12
12
Types of parameters 'x' and 'a' are incompatible.
13
-
Type 'number' is not assignable to type 'T'.
13
+
Type '1' is not assignable to type 'T'.
14
14
'T' could be instantiated with an arbitrary type which could be unrelated to '1'.
15
15
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) => 1'.
0 commit comments