]> source.dussan.org Git - aspectj.git/commitdiff
pr202088: test and fix for coping with abstract annotation pointcuts with context
authoraclement <aclement>
Wed, 7 Nov 2007 11:03:19 +0000 (11:03 +0000)
committeraclement <aclement>
Wed, 7 Nov 2007 11:03:19 +0000 (11:03 +0000)
weaver/src/org/aspectj/weaver/bcel/AtAjAttributes.java

index 61ecd9696fcf4acb4d5ec725cc3faf94e7e0c651..c62c07dbee103715eada329d61d2668bfd9d7de2 100644 (file)
@@ -1176,11 +1176,15 @@ public class AtAjAttributes {
             // this/target/args binding
             final IScope binding;
             try {
-                binding = new BindingScope(
+               if (struct.method.isAbstract()) {
+                   binding = null;
+               } else {
+                    binding = new BindingScope(
                         struct.enclosingType,
                         struct.context,
                         extractBindings(struct)
-                );
+                    );
+               }
             } catch (UnreadableDebugInfoException e) {
                 return;
             }
@@ -1226,7 +1230,7 @@ public class AtAjAttributes {
                                     argumentTypes,
                                     UnresolvedType.forSignature(struct.method.getReturnType().getSignature()),
                                     pc,//can be null for abstract pointcut
-                                    binding
+                                    binding // can be null for abstract pointcut
                             )
                     )
             );