summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/debug/Source-invisible.js
blob: 277c3245971b7f3d9e231102d5834486cc870f6f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// Looking at ScriptSourceObjects in invisible-to-debugger compartments is okay.

var gi = newGlobal({ invisibleToDebugger: true });
gi.eval('function f() {}');

var gv = newGlobal();
gv.f = gi.f;
gv.eval('f = clone(f);');

var dbg = new Debugger;
var gvw = dbg.addDebuggee(gv);
gvw.getOwnPropertyDescriptor('f').value.script.source;