This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug java/19870] New: gcj -C compiled code accessing private fields of inner classes from outer class give IllegalAccessError
- From: "mark at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 10 Feb 2005 00:20:24 -0000
- Subject: [Bug java/19870] New: gcj -C compiled code accessing private fields of inner classes from outer class give IllegalAccessError
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The following compiled with jikes outputs 42.
Compiled with gcj -C and ran with gij gives a java.lang.IllegalAccessError
public class A
{
public static class B
{
private static int i = 42;
}
public static void main(String[] args)
{
System.out.println(B.i);
}
}
--
Summary: gcj -C compiled code accessing private fields of inner
classes from outer class give IllegalAccessError
Product: gcc
Version: 4.0.0
Status: UNCONFIRMED
Keywords: wrong-code
Severity: normal
Priority: P2
Component: java
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: mark at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu
dot org
OtherBugsDependingO 18131
nThis:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19870