archives

« Bugzilla Issues Index

#1866 — 13.1.1.2, Runtime Semantics: Binding Initialisation: No longer possible to use standard Indexed Binding Initialisation


test case:
---
function f(a){}
f()
---

Per the current spec, this should throw a TypeError because the property "0" is not present in the arguments object.


fixed in rev19


Was there an actual change for `arguments` Indexed Binding Initialisation in the next revision, or was this bug closed report b/c of the irrefutable/refutable destructuring changes which happened earlier (i.e. no TypeError thrown for missing properties)? If it's the latter, I still need to file a new ticket for access on `Object.prototype` properties:
---
Object.prototype[0] = "xxx";
function f(a){ return a }
f() === "xxx"
---
Currently returns `true` instead of `false`


yes, it was the reverting the irrefutable/refutable changes that fixed the originally reported problem.

And yes, there is another problem with Object.prototype properties being visible to IndexedBindingInitialization


IndexedBindingInitialization is replaced with IteratorBindingInitization in Rev20 and an iterator over a List of arguments is used, so we don't have any object property issue anymore