Does not overcome the grawlix objection.
/be
On Oct 31, 2011, at 12:20 AM, Jorge wrote:
> On 30/10/2011, at 23:36, Brendan Eich wrote:
>> On Oct 30, 2011, at 12:33 PM, Allen Wirfs-Brock wrote:
>>
>>> The object exemplar approach is just like self or selfish, except that it
>>> builds upon features that are already in JS. Specifically, it uses the new
>>> operator instead of a new method and it names the initialization method
>>> "constructor" in order to tie into the object construction mechanisms that
>>> already exist in JS.
>>
>> +1
>>
>> The only thing I find off the mark is the typography of <|. In light of
>> this, and of the anti-grawlix reaction among many people, could we revisit
>> an infix operator used in restricted productions with [no LineTerminator
>> here] on the left of the operator contextual keyword?
>>
>> Likely keywords include 'proto' (but 'protos' seems better English given the
>> LHS being the prototype object), or my current best shot: 'beget'.
>>
>> let obj = base beget {a: 1, b: 2}
>> let arr = base beget [p, q, r]
>> let fun = base beget function (...args) { ... }
>> let re = base beget /(\w+)\s+(\w)+/g
>>
>> It's still idiomatic as a name for differential inheritance, but it is more
>> pithy than 'make' or 'create' (and one character shorter than 'create' -- no
>> Unix 'creat' reruns! ;-). Comments?
>>
>> Saying or writing "triangle" does not convey meaning, and it's confusing in
>> geometry/graphics contexts.
>
> Perhaps a long arrow may work ?
>
> let object= base <== {a: 1, b: 2};
> --
> Jorge.
> _______________________________________________
> 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