TypeScript/tests/baselines/reference/interfaceWithCallAndConstructSignature.types

23 lines
795 B
Plaintext
Raw Normal View History

2014-08-15 23:33:16 +02:00
=== tests/cases/conformance/interfaces/interfaceDeclarations/interfaceWithCallAndConstructSignature.ts ===
interface Foo {
2015-04-13 23:01:57 +02:00
>Foo : Foo, Symbol(Foo, Decl(interfaceWithCallAndConstructSignature.ts, 0, 0))
2014-08-15 23:33:16 +02:00
(): number;
new (): any;
}
var f: Foo;
2015-04-13 23:01:57 +02:00
>f : Foo, Symbol(f, Decl(interfaceWithCallAndConstructSignature.ts, 5, 3))
>Foo : Foo, Symbol(Foo, Decl(interfaceWithCallAndConstructSignature.ts, 0, 0))
2014-08-15 23:33:16 +02:00
var r = f();
2015-04-13 23:01:57 +02:00
>r : number, Symbol(r, Decl(interfaceWithCallAndConstructSignature.ts, 6, 3))
2014-08-15 23:33:16 +02:00
>f() : number
2015-04-13 23:01:57 +02:00
>f : Foo, Symbol(f, Decl(interfaceWithCallAndConstructSignature.ts, 5, 3))
2014-08-15 23:33:16 +02:00
var r2 = new f();
2015-04-13 23:01:57 +02:00
>r2 : any, Symbol(r2, Decl(interfaceWithCallAndConstructSignature.ts, 7, 3))
2014-08-15 23:33:16 +02:00
>new f() : any
2015-04-13 23:01:57 +02:00
>f : Foo, Symbol(f, Decl(interfaceWithCallAndConstructSignature.ts, 5, 3))
2014-08-15 23:33:16 +02:00