Re: Non-constructible constructors and Arrays

On 2/08/11 5:24 AM, Jonas Sicking wrote:
> Seems better to me to instead make up a new prototype object which
> contains all of Array's non-mutating methods and stick that object on
> the prototype chain of various classes.
> But I'm happy to stick the Array prototype on the prototype chain here
> if that's what the JS folks say is the right solution.

It does mean, however, that we would need to list in Web IDL the set of 
Array prototype functions that get copied across for mutable and 
non-mutable NodeList-like objects.  If ECMAScript grows new ones, we 
would need to update that list.

> But like Boris points out, I think we need to be able to modify this
> on a per-interfaces basis. Either through a opt-in or a opt-out.

Are there particular cases at the moment where we know we would not want 
to opt-in to this?  I'm wondering whether there are such cases.

Received on Tuesday, 2 August 2011 03:46:24 UTC