mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
28 lines
1.1 KiB
Plaintext
28 lines
1.1 KiB
Plaintext
interfaceWithOverloadedCallAndConstructSignatures.ts(10,10): error TS2454: Variable 'f' is used before being assigned.
|
|
interfaceWithOverloadedCallAndConstructSignatures.ts(11,10): error TS2454: Variable 'f' is used before being assigned.
|
|
interfaceWithOverloadedCallAndConstructSignatures.ts(12,14): error TS2454: Variable 'f' is used before being assigned.
|
|
interfaceWithOverloadedCallAndConstructSignatures.ts(13,14): error TS2454: Variable 'f' is used before being assigned.
|
|
|
|
|
|
==== interfaceWithOverloadedCallAndConstructSignatures.ts (4 errors) ====
|
|
interface Foo {
|
|
(): number;
|
|
(x: string): number;
|
|
|
|
new (): any;
|
|
new (x: string): Object;
|
|
}
|
|
|
|
var f: Foo;
|
|
var r1 = f();
|
|
~
|
|
!!! error TS2454: Variable 'f' is used before being assigned.
|
|
var r2 = f('');
|
|
~
|
|
!!! error TS2454: Variable 'f' is used before being assigned.
|
|
var r3 = new f();
|
|
~
|
|
!!! error TS2454: Variable 'f' is used before being assigned.
|
|
var r4 = new f('');
|
|
~
|
|
!!! error TS2454: Variable 'f' is used before being assigned. |