| 1 |
// Copyright (c) 2012 Ecma International. All rights reserved. |
| 2 |
// This code is governed by the BSD license found in the LICENSE file. |
| 3 |
|
| 4 |
/*--- |
| 5 |
es5id: 15.2.3.6-4-289-1 |
| 6 |
description: > |
| 7 |
Object.defineProperty - 'O' is an Arguments object of a function |
| 8 |
that has formal parameters, 'name' is own property which is |
| 9 |
defined in both [[ParameterMap]] of 'O' and 'O', and is deleted |
| 10 |
afterwards, and 'desc' is data descriptor, test 'name' is |
| 11 |
redefined in 'O' with all correct attribute values (10.6 |
| 12 |
[[DefineOwnProperty]] step 3) |
| 13 |
includes: [propertyHelper.js] |
| 14 |
---*/ |
| 15 |
|
| 16 |
; |
| 17 |
(function(a, b, c) { |
| 18 |
delete arguments[0]; |
| 19 |
|
| 20 |
Object.defineProperty(arguments, "0", { |
| 21 |
value: 10, |
| 22 |
writable: true, |
| 23 |
enumerable: true, |
| 24 |
configurable: true |
| 25 |
}); |
| 26 |
|
| 27 |
if (a !== 0) { |
| 28 |
$ERROR("Expected a === 0, actually " + a); |
| 29 |
} |
| 30 |
|
| 31 |
verifyEqualTo(arguments, "0", 10); |
| 32 |
|
| 33 |
verifyWritable(arguments, "0"); |
| 34 |
|
| 35 |
verifyEnumerable(arguments, "0"); |
| 36 |
|
| 37 |
verifyConfigurable(arguments, "0"); |
| 38 |
}(0, 1, 2)); |