Re: map() annotation for iterables?

Boris Zbarsky wrote:
> On 10/5/14, 1:04 AM, Brendan Eich wrote:
>> Right, see https://www.w3.org/Bugs/Public/show_bug.cgi?id=26973#c3.
>
> Right, I'm not talking about for-of but directly doing map/filter 
> operations on iterables. 

Agree we want both. Provided the right class instance (Map for 
MapIterator) is created, the iterable prototype methods seem just as 
generic. This really wants something hard (not impossible, just 
undertested) to add: Iterable.prototype or an unnamed 
%IterablePrototype% above Array.prototype, Map.prototype, Set.prototype, 
etc. Someone please raise on es-discuss, if this seems right.

/be

Received on Sunday, 5 October 2014 05:59:20 UTC