Status: Accepted
Owner: [email protected]
Labels: Type-Bug Priority-Medium

New issue 267 by [email protected]: Indirect eval fails in eval-tainted  
scope.
http://code.google.com/p/v8/issues/detail?id=267

The script
  var foo = "outer";
  (function(fn){var foo="inner"; return [fn("foo")];})(eval)
evaluates to "outer", as it should. The indirect call to eval is correctly
evaluated in the global scope. Changing the second line to;
  (function(fn){var foo="inner"; return [fn("foo"), eval("foo")];})(eval)
makes it fail with an exception:

native v8natives.js:1215: Uncaught EvalError: The "this" object passed to
eval must be the global object from which eval originated

It should have just returned ["outer","inner"].


--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

--~--~---------~--~----~------------~-------~--~----~
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to