shortcut for private(this)

Brendan Eich brendan at mozilla.org
Fri Jan 20 10:42:37 PST 2012


> Herby Vojčík <mailto:herby at mailbox.sk>
> January 20, 2012 10:39 AM
> Brendan Eich wrote:
>> And again, we do not want a reified "private state object", so private
>> could not be a free expression. This also hurts private(other).weight --
>> 'weight' is not an identifier in a "private state object", it has to be
>> a private name object binding. Therefore we should avoid any syntax
>> suggesting a first-class reflection of a private state object.
>
> How do I do private(foo)[expression]? Or I don't (yes, it can be 
> worked around by foo. at store[expression], but)?

No problem -- @foo[bar] is the same in abstract syntax as (@foo)[bar].

/be


More information about the es-discuss mailing list