Re:Running Lua in a browser via Emscripten
by gsnedders on Thursday May 30, 2013 @10:00PM
(#5796442)
I wrote a parenthetical about weak references. I wonder why I deleted it. In short: weakrefs are unlikely to appear any time soon in ES, as they open up all kinds of fun around cross-origin objects (being able to detect their approximate life-time, and that's a fairly major side-channel attack) in some lovely edge-cases.
If you have any more details about this, or even if you don't, please post to es-discuss about it. Currently there is broad consensus on TC39 to add weak references in JS in the future.
Re:Running Lua in a browser via Emscripten
by mwcampbell on Thursday May 30, 2013 @09:46PM
(#5796406)
I was imprecise; Lua has weak tables, not general weak references. So I'd be happy with weak maps in JS.
There has been some discussion about adding more powerful weak refs to JavaScript, but I'm not sure where that discussion stands.