Brendan Eich (2015-02-16T18:35:43.000Z)
Andreas Rossberg wrote:
> On 16 February 2015 at 15:41, Andrea Giammarchi 
> <andrea.giammarchi at gmail.com <mailto:andrea.giammarchi at gmail.com>> wrote:
>
>     Common pattern is to poll.next() a yield until its `done` property
>     is `true` so that a value can be used.
>
>     This is I believe the common case that will create thousands of
>     objects to be quickly trashed as garbage ... so I was wondering if
>     those are all needed
>
>
> Er, I don't think this is the common use case at all. You iterate over 
> something to process values, otherwise there isn't much point in using 
> iterators in the first place.
>
> /Andreas

Right.

Instead of coming up with some bogo-API with a mutable singleton object 
having pigeon-hole problems, how about engine hackers actually do some 
optimizing? I remember in the Mosaic days, Eric Bina replied to someone 
who decried the difficulty of fixing some ostensibly hard bug by writing 
the patch. :-|

/be
d at domenic.me (2015-02-21T00:40:00.165Z)
Andreas Rossberg wrote:

> Er, I don't think this is the common use case at all. You iterate over 
> something to process values, otherwise there isn't much point in using 
> iterators in the first place.

Right.

Instead of coming up with some bogo-API with a mutable singleton object 
having pigeon-hole problems, how about engine hackers actually do some 
optimizing? I remember in the Mosaic days, Eric Bina replied to someone 
who decried the difficulty of fixing some ostensibly hard bug by writing 
the patch. :-|