summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/gc/oomInFindPath.js
blob: 4b3d95688c0a05683c5dc5f31d469f2f620d1d54 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// |jit-test| skip-if: !('oomTest' in this)

var o = { w: { x: { y: { z: {} } } } };
oomTest(() => findPath(o, o.w.x.y.z));

var a = [ , o ];
oomTest(() => findPath(a, o));

function C() {}
C.prototype.obj = {};
var c = new C;

oomTest(() => findPath(c, c.obj));

function f(x) { return function g(y) { return x+y; }; }
var o = {}
var gc = f(o);
oomTest(() => findPath(gc, o));