]> source.dussan.org Git - javassist.git/commitdiff
We also need to keep the annotation default attribute after a prune.
authoradrian <adrian@30ef5769-5b8d-40dd-aea6-55b5d6557bb3>
Wed, 15 Mar 2006 17:11:30 +0000 (17:11 +0000)
committeradrian <adrian@30ef5769-5b8d-40dd-aea6-55b5d6557bb3>
Wed, 15 Mar 2006 17:11:30 +0000 (17:11 +0000)
git-svn-id: http://anonsvn.jboss.org/repos/javassist/trunk@258 30ef5769-5b8d-40dd-aea6-55b5d6557bb3

src/main/javassist/bytecode/MethodInfo.java

index 9307992072d2a0cace9891cda15ad4ad413b81b2..10c77be0c23f80d01c84b8b92c8e73efd4dac805 100644 (file)
@@ -140,6 +140,11 @@ public final class MethodInfo {
             newAttributes.add(visibleAnnotations);
          }
 
+         AnnotationDefaultAttribute defaultAttribute
+              = (AnnotationDefaultAttribute) getAttribute(AnnotationDefaultAttribute.tag);
+         if (defaultAttribute != null)
+             newAttributes.add(defaultAttribute);
+
          ExceptionsAttribute ea = getExceptionsAttribute();
          if (ea != null)
              newAttributes.add(ea);