TypeScript/tests/baselines/reference/interfacedecl.types
2014-08-15 14:37:48 -07:00

96 lines
1.1 KiB
Plaintext

=== tests/cases/compiler/interfacedecl.ts ===
interface a0 {
>a0 : a0
(): string;
(a, b, c?: string): number;
>a : any
>b : any
>c : string
new (): string;
new (s: string);
>s : string
[n: number]: ()=>string;
>n : number
[s: string]: any;
>s : string
p1;
>p1 : any
p2: string;
>p2 : string
p3?;
>p3 : any
p4?: number;
>p4 : number
p5: (s: number) =>string;
>p5 : (s: number) => string
>s : number
f1();
>f1 : () => any
f2? ();
>f2 : () => any
f3(a: string): number;
>f3 : (a: string) => number
>a : string
f4? (s: number): string;
>f4 : (s: number) => string
>s : number
}
interface a1 {
>a1 : a1
[n: number]: number;
>n : number
}
interface a2 {
>a2 : a2
[s: string]: number;
>s : string
}
interface a {
>a : a
}
interface b extends a {
>b : b
>a : a
}
interface c extends a, b {
>c : c
>a : a
>b : b
}
interface d extends a {
>d : d
>a : a
}
class c1 implements a {
>c1 : c1
>a : a
}
var instance2 = new c1();
>instance2 : c1
>new c1() : c1
>c1 : typeof c1