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

20 lines
686 B
Plaintext

=== tests/cases/compiler/functionOverloads15.ts ===
function foo(foo:{a:string; b:number;}):string;
>foo : { (foo: { a: string; b: number; }): string; (foo: { a: string; b: number; }): number; }
>foo : { a: string; b: number; }
>a : string
>b : number
function foo(foo:{a:string; b:number;}):number;
>foo : { (foo: { a: string; b: number; }): string; (foo: { a: string; b: number; }): number; }
>foo : { a: string; b: number; }
>a : string
>b : number
function foo(foo:{a:string; b?:number;}):any { return "" }
>foo : { (foo: { a: string; b: number; }): string; (foo: { a: string; b: number; }): number; }
>foo : { a: string; b?: number; }
>a : string
>b : number