On Tue, Apr 24, 2012 at 4:21 PM, Brendan Eich <[email protected]> wrote:
> Rick Waldron wrote:
>
>> I think the colon was just a typo
>>
>
> Dave is not cc'ed and may have missed the responses going back to Tab's
> first one, but I think there was no typo. Dave's example:
>
> box = {
> _value: 0,
> get: () -> this._value,
> set(v) { this._value = v }
> }
>
>
> Yes, it's awkward as examples go because get and set are contextual
> keywords, but this shows them used as plain identifiers. This also shows ->
> as property value in an object literal (for property name 'get'), well as
> method definition shorthand (for 'set'), to contrast the two styles.
>
>
This makes complete sense now, thank you for the clarification.
Rick
> /be
>
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss