blob: ca093c1baf9ce0a20c5ded6269d4441cecf58615 (
plain)
1
2
3
4
5
6
7
8
9
|
// Accessing a name that isn't a global property is a ReferenceError,
// even if a proxy is on the global's prototype chain.
load(libdir + "asserts.js");
load(libdir + "immutable-prototype.js");
var g = newGlobal();
if (globalPrototypeChainIsMutable())
g.__proto__ = {};
assertThrowsInstanceOf(() => g.eval("s += ''"), g.ReferenceError);
|