The unfortunate result, however, is that a subclass that is *more*
restrictive than the base class is not possible to write robustly - namely,
if someone does `Set.prototype.add.call`, they'll bypass any of the
criteria you've set up in the subclass.

I would have vastly preferred that the base class for both Map and Set used
SameValue, and I'd have found a "SameValueZero" subclass to be much more
trivial to write robustly than a "SameValue" subclass is now. That ship,
unfortunately, has long since sailed.

On Wed, Oct 10, 2018 at 11:09 AM T.J. Crowder <
[email protected]> wrote:

> On Wed, Oct 10, 2018 at 7:03 PM Allen Wirfs-Brock
> <[email protected]> wrote:
> > Yes, exactly.
>
> Thanks!
>
> -- T.J. Crowder
> _______________________________________________
> es-discuss mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/es-discuss
>
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to