OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 1531 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1542 "reduce", getFunction("reduce", ArrayReduce, 1), | 1542 "reduce", getFunction("reduce", ArrayReduce, 1), |
1543 "reduceRight", getFunction("reduceRight", ArrayReduceRight, 1) | 1543 "reduceRight", getFunction("reduceRight", ArrayReduceRight, 1) |
1544 )); | 1544 )); |
1545 | 1545 |
1546 %FinishArrayPrototypeSetup($Array.prototype); | 1546 %FinishArrayPrototypeSetup($Array.prototype); |
1547 | 1547 |
1548 // The internal Array prototype doesn't need to be fancy, since it's never | 1548 // The internal Array prototype doesn't need to be fancy, since it's never |
1549 // exposed to user code. | 1549 // exposed to user code. |
1550 // Adding only the functions that are actually used. | 1550 // Adding only the functions that are actually used. |
1551 SetUpLockedPrototype(InternalArray, $Array(), $Array( | 1551 SetUpLockedPrototype(InternalArray, $Array(), $Array( |
| 1552 "indexOf", getFunction("indexOf", ArrayIndexOf), |
1552 "join", getFunction("join", ArrayJoin), | 1553 "join", getFunction("join", ArrayJoin), |
1553 "pop", getFunction("pop", ArrayPop), | 1554 "pop", getFunction("pop", ArrayPop), |
1554 "push", getFunction("push", ArrayPush) | 1555 "push", getFunction("push", ArrayPush), |
| 1556 "splice", getFunction("splice", ArraySplice) |
1555 )); | 1557 )); |
1556 } | 1558 } |
1557 | 1559 |
1558 SetUpArray(); | 1560 SetUpArray(); |
OLD | NEW |