Re: Elements (extends Array)

On 8/7/13 11:19 PM, Cameron McCormack wrote:
> For Web IDL, if this is a feature that is needed soon, we could just allow
>
>    interface Elements : Array { ... };

If the intent here is to allocate an object that acts just like an Array 
but has additional DOM-object-like behavior, I'd be interested in 
feedback from implementors on how implementable this is likely to be.... 
  In SpiderMonkey the answer is "not very" without at the very least 
noticable performance penalties for either DOM objects (all DOM objects, 
since they could no longer assume certain internal invariants they 
assume now) or arrays, I suspect.

-Boris

Received on Thursday, 8 August 2013 03:45:00 UTC