nodejs/deps/v8/test/mjsunit/regress/regress-crbug-1412487.js
Michaël Zasso 9d7cd9b864
deps: update V8 to 12.8.374.13
PR-URL: https://github.com/nodejs/node/pull/54077
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
2024-08-16 16:03:01 +02:00

35 lines
673 B
JavaScript

// Copyright 2023 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
const arr = [];
const obj0 = {a : 1};
obj0.a1 = 2;
obj0.c = {};
const obj = {a : 1};
obj.a1 = 2;
obj.c = arr;
const f1 = {a : 1};
f1.a1 = 1.1;
arr.push(f1);
for (i = 0; i < 1600; i++) {
const tmp = {a : 1};
tmp.a1 = 1;
tmp['b' + i] = 2;
arr.push(tmp);
}
function workerCode() {
onmessage = function({data:data}) {
postMessage('done');
}
}
worker = new Worker(workerCode, {type: 'function', arguments: []});
worker.postMessage([obj0, obj]);
assertEquals('done', worker.getMessage());