> Dmitry Soshnikov wrote:
>> 
>> Will the "Existential Operator" for properly accessors be something 
>> interesting to consider for ES7 spec? Currently CoffeeScript uses it well.
> 
> Please see
> 
> http://esdiscuss.org/topic/sept-18-tc39-meeting-notes#content-2
> 
> and find "ARB: This is non-compositional".

David seems to suggest a compositional version: `o?.p?.q?.r`

I’m assuming that the left-hand side of `value?.prop` is an arbitrary value and 
that the property access is only made if that value is neither `undefined` nor 
`null`. AFAICT that’s also how CoffeeScript’s existential operator works.

I’m ambivalent about it, though: it would be useful, but would also add 
complexity to the language.

-- 
Dr. Axel Rauschmayer
a...@rauschma.de
rauschma.de

_______________________________________________
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to