答复: javac task encountered a compiling error at the 'import' statement

2011-03-21 Thread 汪燕青
Hi, I've found the reason: JAVA rejects import statements that import a type from the unnamed namespace since v1.4. See also: http://java.sun.com/javase/compatibility_j2se1.4.html#incompatibilities1.4 -邮件原件- 发件人: 汪燕青 [mailto:wangyanq...@gameabc.com] 发送时间: 2011年3月22日 10:48 收件人: Ant Us

答复: javac task encountered a compiling error at the 'import' statement

2011-03-21 Thread 汪燕青
I've tried setting the classpath and sourcepath, still didn't work. But if I removed the problematic import statement, compiling ok, which means the classpath and sourcepath is right. It seems like JAVA forbids this kind of import -- the class to be imported has to have at least 1 prefix. But I

Re: javac task encountered a compiling error at the 'import' statement

2011-03-21 Thread Scot P. Floess
Can we see your build.xml? Sounds like a classpath/srcpath issue... On Tue, 22 Mar 2011, 汪燕青 wrote: Hi everyone,   When I’m building a simple project with ANT 1.8.2, I encountered a compiling error at the import statement of the java code file. There only 2 java files: A.java and com/B.j