some errors in the specification (january 30 version)

Eric Bruneton ebruneton at free.fr
Sat Mar 2 07:00:18 PST 2013


 >Hi Eric,
 >
 >thanks for noticing that the RI stores the
 >RuntimeVisibleTypeAnnotations in the Method instead of a Code
 >attribute.
 >I will discuss how to verify and fix this on the type-annotations-dev
 >mailing list.

I downloaded the latest langtools version (langtools-a9ea02b425ff) and 
now the problem with Method vs Code is fixed, thanks!

But I now have another issue, with annotations on throws clauses. The 
specification uses an unsigned short 
(http://types.cs.washington.edu/jsr308/specification/java-annotation-design.html#class-file:ext:ri:throws) 
but langtools uses an unsigned byte (as can be seen from 
com/sun/tools/classfile/TypeAnnotation.java). ASM uses an unsigned 
short, so I get errors while trying to read a class produced with langtools.

Which version is correct? The specification or the reference implementation?

Eric


More information about the type-annotations-spec-comments mailing list