Cloning WeakSet/WeakMap

Thomas Grainger tagrain at gmail.com
Fri Feb 9 15:03:17 UTC 2018


I think this is referring to cloning a WeakSet into another WeakSet

Thomas Grainger

On 9 February 2018 at 15:01, David Bruant <bruant.d at gmail.com> wrote:

> Hi,
>
> My understanding is that cloning a WeakSet into a Set would remove all its
> properties related to security and garbage collection.
>
> The properties related to security and garbage collection of WeakSet are
> based on the fact that its elements are not enumerable by someone who would
> only be holding a reference to the WeakSet. If you want to "clone" a
> WeakSet into a Set it means you have an expectation that the set of
> elements are deterministically enumerable.
>
> WeakSets and Sets, despite there close name and API, are used in different
> circumstances.
>
> David
>
>
> 2018-02-09 9:53 GMT-05:00 Michał Wadas <michalwadas at gmail.com>:
>
>> Hi.
>>
>> I was asked to include a way to clone WeakSet in Set builtins proposal.
>> Is there any consensus on security of such operation?
>>
>> Michał Wadas
>>
>> _______________________________________________
>> es-discuss mailing list
>> es-discuss at mozilla.org
>> https://mail.mozilla.org/listinfo/es-discuss
>>
>>
>
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20180209/56eaa64c/attachment.html>


More information about the es-discuss mailing list