Couldn’t you have the same advantages if:
- obj.@foo was syntactic sugar for obj[foo]
- @foo was syntactic sugar for [foo] (method definitions, property definitions,
etc.)
foo would be a normal variable and the following two statements would be
equivalent:
private foo;
let foo = new Name();
foo containing a string would also work.
That would be slightly simpler and go together well with your proposed object
model reformation [1]:
https://gist.github.com/3505466
[1] http://wiki.ecmascript.org/doku.php?id=strawman:object_model_reformation
On Aug 29, 2012, at 1:04 , Allen Wirfs-Brock <[email protected]> wrote:
> The strawman is at
> http://wiki.ecmascript.org/doku.php?id=strawman:syntactic_support_for_private_names
>
>
> Allen
> _______________________________________________
> es-discuss mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/es-discuss
--
Dr. Axel Rauschmayer
[email protected]
home: rauschma.de
twitter: twitter.com/rauschma
blog: 2ality.com
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss