mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
21 lines
872 B
Plaintext
21 lines
872 B
Plaintext
externalModuleExportingGenericClass_file0.ts(2,5): error TS2564: Property 'foo' has no initializer and is not definitely assigned in the constructor.
|
|
externalModuleExportingGenericClass_file1.ts(2,8): error TS2314: Generic type 'C<T>' requires 1 type argument(s).
|
|
|
|
|
|
==== externalModuleExportingGenericClass_file1.ts (1 errors) ====
|
|
import a = require('./externalModuleExportingGenericClass_file0');
|
|
var v: a; // this should report error
|
|
~
|
|
!!! error TS2314: Generic type 'C<T>' requires 1 type argument(s).
|
|
var v2: any = (new a()).foo;
|
|
var v3: number = (new a<number>()).foo;
|
|
|
|
==== externalModuleExportingGenericClass_file0.ts (1 errors) ====
|
|
class C<T> {
|
|
foo: T;
|
|
~~~
|
|
!!! error TS2564: Property 'foo' has no initializer and is not definitely assigned in the constructor.
|
|
}
|
|
export = C;
|
|
|
|
|