Skip to Content

Inner classes and inner enums fail, if a package-info.java is present.

Posted in

Hi,

consider the following setup:

A package named "de.soffel.hellorcp" with two classes:
Class Test1.java:

package de.soffel.hellorcp;
public enum Test1 {;
	public enum InnerEnum {}
}

Class Test2.java:

package de.soffel.hellorcp;
public class Test2 {
	public class InnerClass {
	}
}

This works fine with both eclipse build and a4e build.

Now add the file package-info.java to the package dir:

/**
 */
package de.soffel.hellorcp;

This compiles fine with eclipse but a4e produces the following error:

    [javac] 1. ERROR in D:\workspaces\a4e_hellorcp\de.soffel.hellorcp\src\de\soffel\hellorcp\package-info.java (at line 1)
    [javac] /**
    [javac] ^
    [javac] The type package-info is already defined

What's going wrong here?

Best regards,
Georg.

Hi Georg, I try to build jaxb

Hi Georg,

I try to build jaxb generated sources and running into the same issue. Did you solve the problem ?

Regards,
Andre

AE-203

Hi,

we have an issue for this one in our jira system:
http://www.javakontor.org:8080/jira/browse/AE-203

I will fix it this week, fortunately I'm on vacation and have some free time ;-)

Regards,
Gerd