archives

« Bugzilla Issues Index

#4466 — 9.4.4.7 CreateMappedArgumentsObject: Create properties with OrdinaryDefineOwnProperty


9.4.4.7 CreateMappedArgumentsObject ( func, formals, argumentsList, env )

It is necessary to define properties with OrdinaryDefineOwnProperty in CreateMappedArgumentsObject, because the [[ParameterMap]] internal slot is not yet set and [[DefineOwnProperty]] for exotic arguments objects uses that slot. It's not possible to simply move the map allocation before step 15, because the function bindings are not initialized when CreateMappedArgumentsObject is called.


Steps 15.b and 16 need to use [[DefineOwnProperty]].


(In reply to André Bargull from comment #0)
> It's not possible to simply move the map allocation before step 15,

Scratch that. Map allocation can be moved before step 15, but the map initialization needs to happen after installing the indexed arguments properties.


Fixed in ES2016 Draft.