2010/9/2 Mike Shaver <[email protected]>: > On Thu, Sep 2, 2010 at 11:32 AM, Erik Corry <[email protected]> wrote: >> Surely that is the case with WeakMap? At least unless you lost the >> key and don't have any other references to the value. In which case >> you can't reach the value any more, so why would you care whether it >> is kept alive? > > You're right; I forgot about the fact that the keys were not > necessarily value types. Sorry for the noise.
I wonder if this points to potential confusion stemming from the WeakMap name. It seems obvious (and wrong) that a WeakMap would act a little like a HashMap where the values were WeakReferences. Perhaps ObjectMap would be better? -- Erik Corry _______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

