2014-08-15 23:33:16 +02:00
|
|
|
=== tests/cases/compiler/genericWithCallSignatureReturningSpecialization.ts ===
|
|
|
|
interface B<T> {
|
|
|
|
>B : B<T>
|
|
|
|
>T : T
|
|
|
|
|
|
|
|
f(): B<number>;
|
|
|
|
>f : () => B<number>
|
2014-08-19 04:56:03 +02:00
|
|
|
>B : B<T>
|
2014-08-15 23:33:16 +02:00
|
|
|
|
|
|
|
(value: T): void;
|
|
|
|
>value : T
|
|
|
|
>T : T
|
|
|
|
}
|
|
|
|
var x: B<boolean>;
|
|
|
|
>x : B<boolean>
|
2014-08-19 04:56:03 +02:00
|
|
|
>B : B<T>
|
2014-08-15 23:33:16 +02:00
|
|
|
|
|
|
|
x(true); // was error
|
|
|
|
>x(true) : void
|
|
|
|
>x : B<boolean>
|
|
|
|
|