TypeScript/tests/baselines/reference/contextualTyping9.types

15 lines
367 B
Plaintext
Raw Normal View History

2014-08-15 23:33:16 +02:00
=== tests/cases/compiler/contextualTyping9.ts ===
var foo:{id:number;}[] = [{id:1}, {id:2, name:"foo"}];
>foo : { id: number; }[]
>id : number
2014-08-15 23:33:16 +02:00
>[{id:1}, {id:2, name:"foo"}] : { id: number; }[]
>{id:1} : { id: number; }
>id : number
2015-04-13 21:36:11 +02:00
>1 : number
2014-08-15 23:33:16 +02:00
>{id:2, name:"foo"} : { id: number; name: string; }
>id : number
2015-04-13 21:36:11 +02:00
>2 : number
>name : string
2015-04-13 21:36:11 +02:00
>"foo" : string
2014-08-15 23:33:16 +02:00