blob: 5e535eb97dd1de21bc51cfa460f8b101778735fe (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
/*
* Script.prototype.source should be a different object for the same script
* within different debuggers.
*/
let g = newGlobal();
let dbg1 = new Debugger(g);
let dbg2 = new Debugger(g);
var count = 0;
var source;
function test(script) {
++count;
if (!source)
source = script.source;
else
assertEq(script.source != source, true);
};
dbg1.onNewScript = test;
dbg2.onNewScript = test;
g.eval("2 * 3");
assertEq(count, 2);
|