summaryrefslogtreecommitdiffstats
path: root/js/src/tests/non262/lexical-environment/eval-nondefinable-function.js
blob: bd5dcf79787f4ff90457e37326baa0dba6614360 (plain)
1
2
3
4
5
6
7
8
9
10
try {
  eval("var shouldNotBeDefined1; function NaN(){}; var shouldNotBeDefined2;");
} catch (e) {
}

assertEq(Object.getOwnPropertyDescriptor(this, 'shouldNotBeDefined2'), undefined);
assertEq(Object.getOwnPropertyDescriptor(this, 'shouldNotBeDefined1'), undefined);

if (typeof reportCompare === "function")
  reportCompare(true, true);