blob: e4ffcfc349f5ebeaefe6843b2228e61b8f905fd2 (
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)
const g = newGlobal({ newCompartment: true });
const dbg = new Debugger(g);
// Define async generator in debuggee compartment.
g.eval("async function* f() { }");
// Use onEnterFrame hook to create generatorFrames entry.
dbg.onEnterFrame = () => {};
// Trigger failure in AsyncGeneratorNext.
ignoreUnhandledRejections();
oomTest(function() { g.f().next(); });
// Trigger DebugAPI::onSingleStep to check generatorFrames.
dbg.onDebuggerStatement = frame => { frame.onStep = () => {}; }
g.eval("debugger");
|