for-of statement of sparse array

Rick Waldron waldron.rick at
Thu Jul 5 18:30:44 PDT 2012

On Thursday, July 5, 2012 at 9:18 PM, Brendan Eich wrote:

> Brendan Eich wrote:
> > This upholes the Array forEach (and all other extras) hole-skipping. 
> > The deck is stacked against for(;;) iteration in my view.
> > 
> LOL, "This upholds", of course.
I had hoped this was a clever pun :)

Currently, devs expect for-loop and while (assuming common patterns in play here) to be "the expected" way that sparse array holes are exposed -- so from the "give me what I most likely expect" perspective, I agree with the consistency wins argument: for-of should act like for-in 

> /be
> _______________________________________________
> es-discuss mailing list
> es-discuss at

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list