Stack scopes / bindings?
nicolas.albert at gmail.com
Thu Jan 29 14:00:52 UTC 2015
I used to use Rhino and to stack scope through Scriptable.setParentScope
I can not find an equivalent with Bindings or ScriptContext.
- if a variable is defined without var, it's a global variable (root
- if a variable is defined with var, it's a local variable (current
- if a variable is accessed or modified, engine lookup in its current
scope, and parent, and parent parent ... and the global scope
I miss something or this behavior (with setParentScope) doesn't exist ?
More information about the nashorn-dev