TypeScript/tests/baselines/reference/contextualTyping26.types
2015-04-13 14:29:37 -07:00

13 lines
589 B
Plaintext

=== tests/cases/compiler/contextualTyping26.ts ===
function foo(param:{id:number;}){}; foo(<{id:number;}>({}));
>foo : (param: { id: number; }) => void, Symbol(foo, Decl(contextualTyping26.ts, 0, 0))
>param : { id: number; }, Symbol(param, Decl(contextualTyping26.ts, 0, 13))
>id : number, Symbol(id, Decl(contextualTyping26.ts, 0, 20))
>foo(<{id:number;}>({})) : void
>foo : (param: { id: number; }) => void, Symbol(foo, Decl(contextualTyping26.ts, 0, 0))
><{id:number;}>({}) : { id: number; }
>id : number, Symbol(id, Decl(contextualTyping26.ts, 0, 42))
>({}) : {}
>{} : {}