| // Copyright 2009 the Sputnik authors. All rights reserved. |
| // This code is governed by the BSD license found in the LICENSE file. |
| info: Set the value of property length of A to Uint32(length) |
| description: length is object or primitve |
| $ERROR('#1: x = []; x.length = true; x.length === 1. Actual: ' + (x.length)); |
| $ERROR('#2: x = [0]; x.length = null; x.length === 0. Actual: ' + (x.length)); |
| x.length = new Boolean(false); |
| $ERROR('#3: x = [0]; x.length = new Boolean(false); x.length === 0. Actual: ' + (x.length)); |
| x.length = new Number(1); |
| $ERROR('#4: x = []; x.length = new Number(1); x.length === 1. Actual: ' + (x.length)); |
| $ERROR('#5: x = []; x.length = "1"; x.length === 1. Actual: ' + (x.length)); |
| x.length = new String("1"); |
| $ERROR('#6: x = []; x.length = new String("1"); x.length === 1. Actual: ' + (x.length)); |