Could we make %ArrayPrototype%'s [[DefineOwnProperty]] throw or no-op for numeric keys?

2015-04-15 Thread Domenic Denicola
Just an idle thought: Many of the spec-compliance bugs in engines' array implementations over the last couple years have had to do with handling what happens when you e.g. install getters or setters on %ArrayPrototype%. I've been told that handling this case adds lots of complexity to the imple

Re: Could we make %ArrayPrototype%'s [[DefineOwnProperty]] throw or no-op for numeric keys?

2015-04-16 Thread Andreas Rossberg
As long as we have mutable __proto__ in the language that is not going to help. And even then, you'd have to restrict the whole prototype chain, including Object.prototype. AFAICT, the only working solution is to change the behaviour of [[Get]] on arrays, such that they do not consider inherited n

Re: Could we make %ArrayPrototype%'s [[DefineOwnProperty]] throw or no-op for numeric keys?

2015-04-16 Thread Axel Rauschmayer
> As long as we have mutable __proto__ in the language that is not going to > help. And even then, you'd have to restrict the whole prototype chain, > including Object.prototype. > > AFAICT, the only working solution is to change the behaviour of [[Get]] on > arrays, such that they do not consi