]> source.dussan.org Git - aspectj.git/commitdiff
171667: npe guards
authoraclement <aclement>
Fri, 16 Feb 2007 10:02:27 +0000 (10:02 +0000)
committeraclement <aclement>
Fri, 16 Feb 2007 10:02:27 +0000 (10:02 +0000)
org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/problem/AjProblemReporter.java

index 11a1e728d012ec8ee29cdde7e05583428cf801ef..448e543818423f3717cc820f2b87b1643b2c0cd9 100644 (file)
@@ -377,8 +377,12 @@ public class AjProblemReporter extends ProblemReporter {
                for (Iterator i = itMungers.iterator(); i.hasNext(); ) {
                                ConcreteTypeMunger m = (ConcreteTypeMunger)i.next();
                                ResolvedMember sig = m.getSignature();
+                               if (sig==null) continue; // we aren't interested in other kinds of munger
+                               UnresolvedType dType = sig.getDeclaringType();
+                               if (dType==null) continue;
+                               ResolvedType resolvedDeclaringType = dType.resolve(factory.getWorld());
                                ResolvedMember rm = AjcMemberMaker.interMethod(sig,m.getAspectType(),
-                                               sig.getDeclaringType().resolve(factory.getWorld()).isInterface());
+                                               resolvedDeclaringType.isInterface());
                                if (ResolvedType.matches(rm,possiblyErroneousRm)) {
                                        // match, so dont need to report a problem!
                                        return;