David Bruant (2013-12-26T17:20:36.000Z)
domenic at domenicdenicola.com (2014-01-06T14:22:24.439Z)
Found the relevant part of [the notes][1]: > BE: Let's not remain slaves to legacy, Array.from, for-of and spread use only iterable. > > RW: What about pre ES6 environment? > > BE: Can fall back to array-like if needs. I guess this is where I differ as I don't see a need. In ES5 environments, the default `@@iterator` can be embedded in `Array.from`, leading to something like (worst case for explanatory purposes): ````js Array.from = function(x){ if(/*x is a NodeList*/){ // polyfill default NodeList[@@iterator] behavior to create the array to return } if(/*x is an Arguments*/){ // polyfill default Arguments[@@iterator] behavior to create the array to return } // ... } ``` Most likely all of these `@@iterator` polyfills are the same array-like traversals, so there shouldn't be a need to separate each case, they most likely all use the same logic. Rick Waldron: > The array-like part is for all of those objects that _won't_ have an > `@@iterator`, for one reason or another The Conclusion/Resolution section of [the notes][1] suggests: "Add iterator protocol to arguments object (should exist on all things." I went quickly through all the meeting notes I could find and didn't find something about some objects not having an `@@iterator`. [1]: https://github.com/rwaldron/tc39-notes/blob/master/es6/2012-11/nov-29.md#revisit