An "extend" operator is a natural companion to <|

Axel Rauschmayer axel at rauschma.de
Wed Jul 20 02:22:42 PDT 2011


> From: Brendan Eich <brendan at mozilla.com>
> Date: July 19, 2011 18:59:04 GMT+02:00
> To: Sean Eagan <seaneagan1 at gmail.com>
> Cc: es-discuss <es-discuss at mozilla.org>
> Subject: Re: An "extend" operator is a natural companion to <|

> "owns" is ambiguous -- could still delegate. Can't use "extends", the direction is wrong (and "extendedBy" is right out!). How about
> 
>  let b = B copies {...};
> 
> ?
> 
> There must be a better contextual keyword...



How about

    increment copyto obj

Then lhs and rhs are switched, though. What is the best description of what this operator does? “Copy the own properties of an increment to an object”? Whatever word(s) are chosen as an infix operator should reflect such a description. “Extend” and even “increment” do not sound descriptive enough to me.

More ideas:

    obj <-copy- increment
    obj from increment
    obj loads increment
    obj imports increment
    increment to obj
    increment increments obj
    increment overrides obj

-- 
Dr. Axel Rauschmayer

axel at rauschma.de
twitter.com/rauschma

home: rauschma.de
blog: 2ality.com



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20110720/269a19df/attachment-0001.html>


More information about the es-discuss mailing list