TypeScript/tests/baselines/reference/genericClasses1.types
2015-04-15 16:44:20 -07:00

22 lines
309 B
Plaintext

=== tests/cases/compiler/genericClasses1.ts ===
class C<T> {
>C : C<T>
>T : T
public x: T;
>x : T
>T : T
}
var v1 = new C<string>();
>v1 : C<string>
>new C<string>() : C<string>
>C : typeof C
var y = v1.x; // should be 'string'
>y : string
>v1.x : string
>v1 : C<string>
>x : string