Strange Java error with annotations -


Try typing:

  list & lt; Object & gt; List; @SuppressWarnings ("uncheck") list = (list & gt; object & gt;) new object ();  

This << p>

 list can not be sorted in a way 

I understand how this annotation works. Even the logic behind it knows?

Edit: Thanks for the quick reply I knew that this works if even the assignment is made a declaration.

You comment on the manifesto, not just the assignment. This compiled:

  @SuppressWarnings ("uncheck") list & lt; Object & gt; List = (list & gt; object & gt;) new object (); See Jawadox for  
List targets.

And if you look, then it says:

local variable declaration

(no target Arbitrary statement, so any annotation possibly can not go there and still allows it to be compiled.)


Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -