|
|
|
8. Set obj .[[BoundTargetFunction]] to targetFunction . 9. Set obj .[[BoundThis]] to boundThis . 10. Set obj .[[BoundArguments]] to boundArgs . 11. Return obj . An Array object is an that gives special treatment to ). A property whose is an is also called an element . Every Array object has a non-configurable "length" property whose value is always a non-negative whose 32 . The value of the "length" property is numerically greater than the name of every own property whose name is an ; whenever an own property of an Array object is created or changed, other properties are adjusted as necessary to the "length" property is changed, if necessary, to be one more than the numeric value of that whenever the value of the "length" property is changed, every own property whose name is an whose value is not smaller than the new length is deleted. This constraint applies only to own properties of an Array object "length" properties that may be inherited from its prototypes. NOTE An object is an Array exotic object (or simply, an Array object) if its [[DefineOwnProperty]] internal method uses the following implementation, and its other essential internal methods use the definitions found in . These methods are installed in . The [[DefineOwnProperty]] internal method of an
A takes arguments P (a property key) and Desc (a ). It performs the following steps when called: 1. : P ) is true . 2. If P is "length" , then a. Return ? A , Desc ). 3. Else if P is an , then a. Let oldLenDesc be ( A , "length" ). b. oldLenDesc ) is true . c. : oldLenDesc .[[Configurable]] is false . d. Let oldLen be oldLenDesc .[[Value]]. e. : oldLen is a non-negative . f. Let index be ! P ). g. If index
≥
oldLen and oldLenDesc .[[Writable]] is false , return false . h. Let succeeded A , P , Desc ). i. If succeeded is false , return false . j. If index
≥
oldLen , then i. Set oldLenDesc .[[Value]] to index + 1 𝔽 . ii. Let succeeded A , "length" , oldLenDesc ). iii. : succeeded is true . A String
P is an ( P )) equals P and ( P ) is not the same value as (2 32 - 1). 10.4.2 Array Exotic Objects 10.4.2.1 [[DefineOwnProperty]] ( P , Desc ) 243 |