Removal of WeakMap/WeakSet clear

Benjamin Gruenbaum inglor at
Mon Dec 8 17:05:38 PST 2014

Never been a need?

Why if you want to use objects as keys and not use reference equality? We've been over this.

Here's a ref

> On Dec 8, 2014, at 23:46, Tab Atkins Jr. <jackalmage at> wrote:
>> On Thu, Dec 4, 2014 at 9:46 PM, Katelyn Gadd <kg at> wrote:
>> I'm surprised to hear that JS runtimes don't necessarily have ways to
>> 'hash' a given JS value, but it makes sense. I can see how that is a
>> great reason for 'get me a hash for this value' to never actually
>> exist in the API, even if it's unfortunate that I have to recreate
>> that facility myself in runtimes that do have it.
> JS has maps/sets that take objects natively, hiding any details about
> how a mutable object is tracked/stored as keys or values, so there's
> never been any need for such a thing.  Explicitly exposing hash codes
> is leaking implementation details into the user-facing API.
> ~TJ
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list