10 lines
615 B
Plaintext
10 lines
615 B
Plaintext
==== tests/cases/compiler/genericAssignmentCompatOfFunctionSignatures1.ts (2 errors) ====
|
|
var x1 = function foo3<T, U extends { a: T; b: string }>(x: T, z: U) { }
|
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
!!! Constraint of a type parameter cannot reference any type parameter from the same type parameter list.
|
|
var x2 = function foo3<T, U extends { a: T; b: number }>(x: T, z: U) { }
|
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
!!! Constraint of a type parameter cannot reference any type parameter from the same type parameter list.
|
|
|
|
x1 = x2;
|
|
x2 = x1; |