[whatwg] Adding ECMAScript 5 array extras to HTMLCollection

Garrett Smith dhtmlkitchen at gmail.com
Fri Jul 30 09:48:56 PDT 2010


On 7/29/10, Garrett Smith <dhtmlkitchen at gmail.com> wrote:
> On 7/29/10, Ian Hickson <ian at hixie.ch> wrote:
>>
>> The e-mails quoted below consist of the salient points of this thread:
>>
>> On Fri, 23 Apr 2010, David Bruant wrote:
>>>
>
[...]
> The difficulty is getting the special behavior for [[Get]] which would
> seem to require some sort of catchall behavior that I linked to
> earlier and when it comes to [[HasProperty]] checks, that can be
> complicated (e.g. `"0" in document.forms` doesn't work).
>

It was the FORM element where [[HasProperty]] sometimes results false
where [[Get]] results in an object:

  var aForm = document.forms[0];
  [typeof aForm[0], "0" in aForm];

Result in FF: "object", false

[[Get]] access for various collections is defined for each collection
and doesn't work consistently as specified.


More information about the whatwg mailing list