Huston, we have a problem !

Joe Darcy joe.darcy at oracle.com
Fri Feb 18 10:57:05 PST 2011


Zdeněk Troníček wrote:
> Rémi Forax napsal(a):
>   
>> On 02/18/2011 07:08 PM, "Zdeněk Troníček" wrote:
>>     
>>> As far as I understood the original question, it was as follows: Why we
>>> need to write
>>>
>>> List<Integer>  p = new ArrayList<>();
>>>
>>> and not only
>>>
>>> List<Integer>  p = new ArrayList(); ?
>>>
>>> Is there any special reason for<>?
>>>
>>> Z.
>>>       
>> List<Integer>  p = new ArrayList(new ArrayList<String>());  // ok
>>
>> List<Integer>  p = new ArrayList<>(new ArrayList<String>());  // not ok
>>
>>     
>
> The problem is that the first line is apparently wrong. Do you feel as an
> obligation to be backward compatible with code that is wrong?
>
>
>   

This discussion is off-topic.  The differences between diamond and raw 
types and the advantages of diamond were well-covered on coin-dev when 
the proposal was first discussed.

Please check the archives.

-Joe





More information about the coin-dev mailing list