Partial implementation of the Array.prototype built-in object.

This commit is contained in:
Ruben Ayrapetyan
2014-09-26 20:07:45 +04:00
parent 0e22967653
commit 47d384c565
3 changed files with 308 additions and 1 deletions
+6
View File
@@ -65,3 +65,9 @@ b.length = 5;
assert(b[50000] === undefined);
assert(([1, 2, 3]).length === 3);
assert(Array.prototype.constructor === Array);
assert(Array.prototype.length === 0);
Array.prototype[0] = 'string value';
assert(Array.prototype.length === 1);
assert(Array.prototype[0] === 'string value');