[Bug libgcj/30076] Annotations don't work with interpreted code
aph at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Dec 5 18:54:00 GMT 2006
------- Comment #1 from aph at gcc dot gnu dot org 2006-12-05 18:54 -------
Created an attachment (id=12749)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=12749&action=view)
.
Expected output:
class pp: @A1(enumF=ACE, doubleF=99.0, stringF=A1, arrayF=[1, 2], intF=0,
classF=class java.lang.Class, nestedF=@Inner(stringInnerF=class annotation))
class pp: @Another(classF=class java.lang.Integer)
public static void pp.barf(int,int):
arg 0: @Inner(stringInnerF=Param anno)
arg 1: @Another(classF=class pp)
arg 1: @Inner(stringInnerF=second anno)
public static void pp.main(java.lang.String[]):
@A1(enumF=DEUCE, doubleF=99.0, stringF=ff, arrayF=[33], intF=2868724,
classF=class java.lang.Class, nestedF=@Inner(stringInnerF=another method))
public static transient void pp.write(java.lang.String[]):
@A1(enumF=ACE, doubleF=3.0, stringF=Abandon hope, arrayF=[0], intF=12,
classF=class pp, nestedF=@Inner(stringInnerF=method annotation))
public final native void java.lang.Object.wait(long) throws
java.lang.InterruptedException:
public final void java.lang.Object.wait(long,int) throws
java.lang.InterruptedException:
public boolean java.lang.Object.equals(java.lang.Object):
public int pp.arse:
@Another(classF=class java.lang.String)
@Inner(stringInnerF=field)
public int pp.too:
@Inner(stringInnerF=ff)
What we get:
~/gcc/gcj-eclipse-merge-branch/install/bin/gij pp
Exception in thread "main" java.lang.NullPointerException
at java.lang.Class.getDeclaredAnnotationsInternal(natClass.cc:1389)
at java.lang.Class.getDeclaredAnnotations(Class.java:1305)
at java.lang.Class.getAnnotations(Class.java:1275)
at pp.main(pp.java:80)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30076
More information about the Java-prs
mailing list