[Caja] GC of name objects in ES3.1

# David-Sarah Hopwood (17 years ago)

Mike Samuel wrote:

Mark,

Do you know if the ES3.1 spec specifies GC behavior around Name objects that are not referenced from any reachable or executing functions' scope chains, and are not a key for any enumerable property?

Typically language specs don't normatively specify GC behaviour, because it isn't observable except for the effect on memory usage, and they don't specify memory usage. But it does deserve a footnote, IMHO.

In Erlang, atoms are not GC'd, and this leads to all kinds of ugly workarounds. This behaviour is widely considered to be a wart, and there is a proposal to fix it: www.erlang.org/eeps/eep-0020.html. (That document mainly discusses implementation in Erlang/OTP, but the motivation and rationale sections are relevant.) It would be nice not to repeat this mistake in ECMAScript.

If not, is this an issue that should be raised on one of the es*-discuss lists?

Cc: and Reply-To: set to es-discuss.

# Brendan Eich (17 years ago)

On Oct 9, 2008, at 6:04 PM, David-Sarah Hopwood wrote:

Mike Samuel wrote:

Mark,

Do you know if the ES3.1 spec specifies GC behavior around Name
objects that

No Name objects in ES3.1.