package-info.java compiled name
Jonathan Gibbons
jonathan.gibbons at oracle.com
Tue Aug 2 20:16:18 UTC 2022
That's definitely a bug in either javac or javap.
-- Jon
On 8/1/22 12:29 AM, Andrey Turbanov wrote:
> Hello.
> We found confusing behaviour of javac, when it compiles package-info.java
> On Windows name of compiled _inteface_ contains backslashes:
>
> client>javap package-info.class
> Compiled from "package-info.java"
> interface some\org\client\package-info {
> }
>
> On Linux it looks ok:
>
> client$ javap package-info.class
> Compiled from "package-info.java"
> interface some.org.client.package-info {
> }
>
> It turns out, such behaviour breaks AspectJ code -
> https://github.com/eclipse/org.aspectj/issues/176 (sample maven
> project - https://github.com/eclipse/org.aspectj/files/9188154/dxcore-temp.zip)
> I believe content of class file shouldn't not depend on compilation platform.
> Is there a reason why javac behaves like this?
>
>
> Best regards,
> Andrey Turbanov
More information about the compiler-dev
mailing list