2014-08-15 23:33:16 +02:00
|
|
|
=== tests/cases/compiler/arrayConcatMap.ts ===
|
|
|
|
var x = [].concat([{ a: 1 }], [{ a: 2 }])
|
|
|
|
>x : any[]
|
2014-08-22 03:39:46 +02:00
|
|
|
>[].concat([{ a: 1 }], [{ a: 2 }]) .map(b => b.a) : any[]
|
|
|
|
>[].concat([{ a: 1 }], [{ a: 2 }]) .map : <U>(callbackfn: (value: any, index: number, array: any[]) => U, thisArg?: any) => U[]
|
2014-08-15 23:33:16 +02:00
|
|
|
>[].concat([{ a: 1 }], [{ a: 2 }]) : any[]
|
|
|
|
>[].concat : { <U extends any[]>(...items: U[]): any[]; (...items: any[]): any[]; }
|
|
|
|
>[] : undefined[]
|
|
|
|
>concat : { <U extends any[]>(...items: U[]): any[]; (...items: any[]): any[]; }
|
|
|
|
>[{ a: 1 }] : { a: number; }[]
|
|
|
|
>{ a: 1 } : { a: number; }
|
|
|
|
>a : number
|
|
|
|
>[{ a: 2 }] : { a: number; }[]
|
|
|
|
>{ a: 2 } : { a: number; }
|
|
|
|
>a : number
|
|
|
|
|
|
|
|
.map(b => b.a);
|
|
|
|
>map : <U>(callbackfn: (value: any, index: number, array: any[]) => U, thisArg?: any) => U[]
|
|
|
|
>b => b.a : (b: any) => any
|
|
|
|
>b : any
|
|
|
|
>b.a : any
|
|
|
|
>b : any
|
|
|
|
>a : any
|
|
|
|
|