Strict mode eval

Andreas Rossberg rossberg at google.com
Thu May 12 02:10:41 PDT 2011


On 11 May 2011 23:15, Allen Wirfs-Brock <allen at wirfs-brock.com> wrote:
> "Direct eval"  (or the eval operator, as Oliver refers to it) is a way to
> (mostly) statically identify eval calls and to do special case processing to
> make the caller environment information available for eval processing.
>  "indirect evals" are just regular function calls and not special
> environment information is passed or otherwise made available.  So, the
> built-in eval function when indirectly involved is limited to using the
> global environment.
> This has nothing to do with strict mode.

Sorry, I should have been clearer. To clarify: my follow-up question
was only tangentially related to the question of direct calls -- it
mainly was about how eval inherits strict mode.

The one bit where these questions are somewhat related is the
"(mostly)" bit in your reply. Is there a reason for this "mostly",
which, I would argue, is a form of dynamic scoping?

/Andreas


More information about the es-discuss mailing list