1
// Frame.prototype.this in strict-mode functions, with primitive values
3
var g = newGlobal('new-compartment');
4
var dbg = new Debugger(g);
6
dbg.onDebuggerStatement = function (frame) {
8
assertEq(frame.this, g.v);
11
g.eval("function f() { 'use strict'; debugger; }");
13
g.eval("Boolean.prototype.f = f; v = true; v.f();");
15
g.eval("Number.prototype.f = f; v = 3.14; v.f();");
17
g.eval("String.prototype.f = f; v = 'hello'; v.f();");
19
g.eval("v = undefined; f.call(v);");
20
g.eval("v = null; f.call(v);");