groovy-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Sun <realblue...@hotmail.com>
Subject Re: Constructor call short-hand syntax
Date Tue, 04 Sep 2018 04:49:00 GMT
Hi Paul,

     Safe index is only for accessing the elements of collections and object
properties, but not for creating instance. The collections and objects may
be null, so we designed the "safe" index.

     To sum up, I vote -1 to support syntax like `Date[time:0]`, the class
instance will not be null.

Cheers,
Daniel.Sun



--
Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html

Mime
View raw message