2014-10-01 02:15:18 +02:00
|
|
|
declare function D(): string; // error
|
2014-07-13 01:04:16 +02:00
|
|
|
|
2014-10-01 02:15:18 +02:00
|
|
|
declare class D { constructor (value: number); } // error
|
2014-07-13 01:04:16 +02:00
|
|
|
|
|
|
|
var s1: string = D(); // OK
|
|
|
|
|
|
|
|
var s2: string = (new D(1))();
|
|
|
|
|
|
|
|
declare class C { constructor(value: number); }
|
|
|
|
(new C(1))(); // Error for calling an instance
|