OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2017 the V8 project authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 // Flags: --verify-heap | |
6 | |
7 class Array1 extends Array { | |
8 constructor(len) { | |
9 super(1); | |
10 } | |
11 }; | |
12 | |
13 class MyArray extends Array { | |
14 static get [Symbol.species]() { | |
15 return Array1; | |
16 } | |
17 } | |
18 | |
19 a = new MyArray(); | |
20 | |
21 for (var i = 0; i < 100000; i++) { | |
22 a.push(1); | |
23 } | |
24 | |
25 a.map(function(x) { return 42; }); | |
OLD | NEW |