Operator overloading for non-value objects

Brendan Eich brendan at mozilla.com
Mon Jan 13 07:40:48 PST 2014

Anne van Kesteren wrote:
> On Mon, Jan 13, 2014 at 1:13 PM, Dean Landolt<dean at deanlandolt.com>  wrote:
>> >  Value Objects. See the recent thread re: value objects on es-discuss. Slides
>> >  from the presentation Brendan linked to
>> >  (http://www.slideshare.net/BrendanEich/js-resp) confirm that == will still
>> >  be overloadable and he says he'll be working on writing it all up this
>> >  month.
> Value objects are immutable. URL objects do not have that quality
> which is why I titled this thread overloading for non-value objects...

Then no == for URL objects.

We want to keep the relatively few invariants in the language that we 
have. Why is it so important to have == for (mutable) URLs?


More information about the es-discuss mailing list