=== tests/cases/compiler/underscoreMapFirst.ts === declare module _ { >_ : typeof _ interface Collection { } >Collection : Collection >T : T interface List extends Collection { >List : List >T : T >Collection : Collection >T : T [index: number]: T; >index : number >T : T length: number; >length : number } interface ListIterator { >ListIterator : ListIterator >T : T >TResult : TResult (value: T, index: number, list: T[]): TResult; >value : T >T : T >index : number >list : T[] >T : T >TResult : TResult } interface Dictionary extends Collection { >Dictionary : Dictionary >T : T >Collection : Collection >T : T [index: string]: T; >index : string >T : T } export function pluck( >pluck : (list: Collection, propertyName: string) => any[] >T : T list: Collection, >list : Collection >Collection : Collection >T : T propertyName: string): any[]; >propertyName : string export function map( >map : (list: List, iterator: ListIterator, context?: any) => TResult[] >T : T >TResult : TResult list: List, >list : List >List : List >T : T iterator: ListIterator, >iterator : ListIterator >ListIterator : ListIterator >T : T >TResult : TResult context?: any): TResult[]; >context : any >TResult : TResult export function first(array: List): T; >first : (array: List) => T >T : T >array : List >List : List >T : T >T : T } declare class View { >View : View model: any; >model : any } interface IData { >IData : IData series: ISeries[]; >series : ISeries[] >ISeries : ISeries } interface ISeries { >ISeries : ISeries items: any[]; >items : any[] key: string; >key : string } class MyView extends View { >MyView : MyView >View : View public getDataSeries(): ISeries[] { >getDataSeries : () => ISeries[] >ISeries : ISeries var data: IData[] = this.model.get("data"); >data : IData[] >IData : IData >this.model.get("data") : any >this.model.get : any >this.model : any >this : MyView >model : any >get : any >"data" : string var allSeries: ISeries[][] = _.pluck(data, "series"); >allSeries : ISeries[][] >ISeries : ISeries >_.pluck(data, "series") : any[] >_.pluck : (list: _.Collection, propertyName: string) => any[] >_ : typeof _ >pluck : (list: _.Collection, propertyName: string) => any[] >data : IData[] >"series" : string return _.map(allSeries, _.first); >_.map(allSeries, _.first) : ISeries[] >_.map : (list: _.List, iterator: _.ListIterator, context?: any) => TResult[] >_ : typeof _ >map : (list: _.List, iterator: _.ListIterator, context?: any) => TResult[] >allSeries : ISeries[][] >_.first : (array: _.List) => T >_ : typeof _ >first : (array: _.List) => T } }