groovy-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Sun <>
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.


Sent from:

View raw message