On 12 June 2013 17:35, Michael Schwartz <[email protected]> wrote:
> How is the template compiler to figure out i is a global reference?
>
> LOTS of code.
>
> That's the point.  The template compiler could be 50 lines using with.

IIUC, you don't want 'i' to pollute the global name space? Then don't
use an undeclared variable. Unfortunately, JavaScript allows it, but
it's a general bug of the language, not specific to templates. Trying
to "fix" one broken feature with another broken feature is not a good
idea. Instead, don't use the broken feature. Put a "use strict" into
the generated code if you want to rule out accidents.

/Andreas

-- 
-- 
v8-users mailing list
[email protected]
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to