Brendan Eich wrote: > On Jan 15, 2009, at 4:54 PM, David-Sarah Hopwood wrote: >> Brendan Eich wrote: >>> On Jan 15, 2009, at 9:50 AM, Erik Arvidsson wrote: >>> >>>> Is there a reason why we need to restrict the argArray to apply this >>>> much? I think it would be very useful to allow anything array like >>>> here. >>> >>> Please define "array like" and give examples (possibly including DOM >>> nodelists, which thanks to "live update" are are neither lists nor >>> arrays, rather more like cursors). >> >> "array-like" means having 'length' and array index properties. > > And the constraint that index < length for all index properties?
No. > And other constraints from ES1-3 [section 15.4] as follows? No. If I'd meant to include those constraints, I would have said so. The constraints are not needed here. You just read 'length' using [[Get]], and then read each array index property from 0 to ToUint32(length)-1 inclusive using [[Get]]. This is how all of the generic methods that operate on array-like objects work. I think you're making mountains out of molehills in this subthread; a Function.prototype.apply that treats its arguments array generically is quite easy to specify (and implement). -- David-Sarah Hopwood _______________________________________________ Es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

