Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » [JDT UI] Small bug in Content Assist
[JDT UI] Small bug in Content Assist [message #717282] Fri, 19 August 2011 20:15 Go to next message
Romain Dervaux is currently offline Romain DervauxFriend
Messages: 40
Registered: July 2009
Member
Hi all

I just noticed a problem with the Content Assist. (tested with Indigo)
Assume this class :

public class Test {

private void test () {
List<? extends Integer> liste = null;
}
}

if you type
liste.
under the decleration of the variable 'liste', the content assist will
appear.

It will propose the following methods :
add(null e)
add(int index, null e)
addAll(null c)
addAll(int index, null c)
set(int index, null element)

Sorry if the bug has already been discovered.
Please tell me if i should open a new bug in bugzilla.
Thanks
Re: [JDT UI] Small bug in Content Assist [message #717687 is a reply to message #717282] Mon, 22 August 2011 04:48 Go to previous messageGo to next message
Satyam Kandula is currently offline Satyam KandulaFriend
Messages: 444
Registered: July 2009
Senior Member
Please file the bug. It is not assignment to null which is causing the problem, but it doesn't seem to like '? extends xxxx'.
Re: [JDT UI] Small bug in Content Assist [message #717844 is a reply to message #717687] Mon, 22 August 2011 13:55 Go to previous messageGo to next message
Michael Pellaton is currently offline Michael PellatonFriend
Messages: 289
Registered: July 2009
Senior Member
Hi

> List<? extends Integer>
Is this a java.lang.Integer?

If so, the declaration above makes no sense as Integer is a final class
and cannot be extended:

public final class Integer extends Number implements Comparable<Integer>


Could it be that this is the reason?

Michael
Re: [JDT UI] Small bug in Content Assist [message #717923 is a reply to message #717844] Mon, 22 August 2011 17:50 Go to previous message
Romain Dervaux is currently offline Romain DervauxFriend
Messages: 40
Registered: July 2009
Member
Yep, you're right.
I think the compiler should tag this as error, or at least a warning...

URL of the bug : https://bugs.eclipse.org/bugs/show_bug.cgi?id=172925


Le 22/08/2011 15:55, Michael Pellaton a écrit :
> Hi
>
>> List<? extends Integer>
> Is this a java.lang.Integer?
>
> If so, the declaration above makes no sense as Integer is a final class
> and cannot be extended:
>
> public final class Integer extends Number implements Comparable<Integer>
>
>
> Could it be that this is the reason?
>
> Michael
Previous Topic:Maven & IDL generated-sources
Next Topic:External builder - portably
Goto Forum:
  


Current Time: Wed Apr 24 20:00:24 GMT 2024

Powered by FUDForum. Page generated in 0.02826 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top