> I believe that we could grammatically use ArrowBody as the body of concise 
> methods in object literals and classes.  In that case, Dave's example could 
> be expressed as:
> 
>     box = {
>         _value: 0,
>         unbox() ()-> this._value,
>         setbox(v)  this._value = v 
>     }

That would be very nice. And it would be a perfect solution for the completion 
value issue: If you want to implicitly return the completion value, use an 
expression body.

Is there a typo in the code? I’d expect it to be:

    box = {
        _value: 0,
        unbox() this._value,
        setbox(v)  this._value = v
    }

-- 
Dr. Axel Rauschmayer
[email protected]

home: rauschma.de
twitter: twitter.com/rauschma
blog: 2ality.com

_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to