Notes on implementing concise calls to constructors with type parameters
Ulf Zibis
Ulf.Zibis at gmx.de
Thu May 14 04:39:07 PDT 2009
Am 14.05.2009 06:42, Joseph D. Darcy schrieb:
> Mark Derricutt wrote:
>
>> If you were going to use this syntax, why not be somewhat consistent with
>> the dynamic language folk and go for:
>>
>> def foo = new ArrayList<String>();
>>
>>
>
> Java is not a dynamic language; I find declaring the full type on the
> left hand side (e.g. "List<String>") and initializing with the
> implementation type but without repeating the type parameter (e.g. "new
> ArrayList<>()") to be easy to read and more in keeping with the design
> of Java.
>
> -Joe
>
>
+1
-Ulf
More information about the coin-dev
mailing list