On Wed, Oct 3, 2012 at 11:34 AM, Brendan Eich <[email protected]> wrote: >> * the spread syntax just uses the iteration protocol; > > This differs from Array.from -- any reason not to fall back on the > array-like protocol (which for missing 'length' iterates no values)?
I think ES6 should have a single how-to-iterate behavior shared by Array.from, spread syntax, and for-of. Whether that includes a fallback to .length or not seems less important to me. It seems simpler *not* to include the fallback. Firefox doesn't include it at present. Instead, arraylike objects are pretty much all iterable. That wasn't hard to do, since our Array.prototype.iterator is generic. -j _______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

