Namespaces as Sugar (was: complexity tax)
mike.shaver at gmail.com
Wed May 28 05:36:58 PDT 2008
On Wed, May 28, 2008 at 2:46 AM, Maciej Stachowiak <mjs at apple.com> wrote:
> I think it would be simpler to limit the effect of namespaces to lexical
> bindings (where we know we can bind to the right name and namespace
> statically in any case of interest) and not have them affect object property
> lookup in general.
OK, that would be simpler, though I do worry about breaking the
"window.whatever is the global whatever" model a bit for web
developers. Thanks for the explanation.
Given that namespaced lookup is used on the scope chain, |with
(window)| would then do namespaced lookups, albeit perhaps more
slowly? Does that also mean that |with (someobj)| will be a way to
get namespaced lookup on non-global objects?
More information about the Es4-discuss