Build error in Eclipse

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Build error in Eclipse

Nigel-7
I get the following error in Eclipse when compiling Hudson on the  
latest MacOS Java6:

hudson-core/src/main/java/hudson/model/Job.java, line 505
The method getPropertyDescriptors(Class<? extends Job>) in the type  
JobPropertyDescriptor is not applicable for the arguments  
(Class<capture-of ?>)

Anyone else see this?  I'm new to Eclipse, so perhaps this is a  
config problem on my part.

Cheers,
Nige

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Build error in Eclipse

Kohsuke Kawaguchi
Administrator
Nigel wrote:

> I get the following error in Eclipse when compiling Hudson on the  
> latest MacOS Java6:
>
> hudson-core/src/main/java/hudson/model/Job.java, line 505
> The method getPropertyDescriptors(Class<? extends Job>) in the type  
> JobPropertyDescriptor is not applicable for the arguments  
> (Class<capture-of ?>)
>
> Anyone else see this?  I'm new to Eclipse, so perhaps this is a  
> config problem on my part.
Most likely it's a bug in JDT --- the java compiler in Eclipse. Try
changing the code to:

     for (JobPropertyDescriptor d :
JobPropertyDescriptor.getPropertyDescriptors((Class)getClass())) {

to see if that fixes it. If that works, feel free to commit that change.

--
Kohsuke Kawaguchi
Sun Microsystems                   [hidden email]

smime.p7s (4K) Download Attachment