On Nov 12, 2011, at 5:10 AM, Russell Leggett wrote:
>> 
> 
> Regardless of the implementation of primitive values, couldn't we say that 
> the semantics of a weak map ignore primitive keys and look only at the value. 
> Primitive keys are exceptionally common for maps, and this would open up a 
> lot of potential uses, especially regarding caching.
> 


What you are asking for is a "weak array" (or an array of "weak references").  
While some people think that such things have utility others are concerned that 
they expose GC based non-determination which they don't want to allow into the 
language.

Allen


_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to