michael@0: /* michael@0: * Any copyright is dedicated to the Public Domain. michael@0: * http://creativecommons.org/licenses/publicdomain/ michael@0: * Contributor: Jason Orendorff michael@0: */ michael@0: michael@0: if (typeof evalcx == 'function') { michael@0: var cx = evalcx(""); michael@0: evalcx("function f() { return this; }", cx); michael@0: f = cx.f; michael@0: assertEq(f(), cx); michael@0: michael@0: evalcx("function g() { 'use strict'; return this; }", cx); michael@0: g = cx.g; michael@0: assertEq(g(), undefined); michael@0: } michael@0: michael@0: reportCompare(0, 0, "ok");