Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » Strange eclipse compilation error
Strange eclipse compilation error [message #189836] Thu, 16 December 2004 15:35 Go to next message
Eclipse UserFriend
Originally posted by: cao.mobilematrix.net

Hi,

I'm using eclipse 3.0.1 build 200409161125 with latest JDT etc. I got
strange compilation errors only when extending PrintWriter and
implementing Runnable at the same time.

here is the sample code

import java.io.OutputStreamWriter;
import java.io.PrintWriter;
public class Test extends PrintWriter implements Runnable {
public Test(OutputStreamWriter out, boolean flag) {
super(out, flag);
}
public void run() {
}
}

here is the error:

The return type is incompatible with Writer.append(char),
PrintWriter.append(char)

When I use ant to compile, I have no problem at all. Did anyone see this
before? Could this be a bug in eclipse or that code does have something
wrong?

Any hint would be highly appreciated!

Cao

PS: my os = windows xp home with sp2;
my java = 1.5.0 build 1.5.0-b64
Re: Strange eclipse compilation error [message #189857 is a reply to message #189836] Thu, 16 December 2004 17:24 Go to previous message
Eclipse UserFriend
Originally posted by: olivier_thomannNOSPAM.ca.ibm.com

G Cao a écrit :
> The return type is incompatible with Writer.append(char),
> PrintWriter.append(char)
>
> When I use ant to compile, I have no problem at all. Did anyone see this
> before? Could this be a bug in eclipse or that code does have something
> wrong?
>
> Any hint would be highly appreciated!
If you use 1.5 libraries, compile using the compliance 1.5 or switch to
1.4 librairies.
--
Olivier
Previous Topic:Code templates using ${line_selection}
Next Topic:Cannot step in debugged apps
Goto Forum:
  


Current Time: Wed Jul 16 17:50:04 EDT 2025

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

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

Back to the top