aboutsummaryrefslogtreecommitdiffstats
path: root/org.aspectj.ajdt.core
diff options
context:
space:
mode:
authoracolyer <acolyer>2004-03-15 22:38:03 +0000
committeracolyer <acolyer>2004-03-15 22:38:03 +0000
commit5c67166488df998bc208567c2fd27f21b52592c5 (patch)
tree9d697207ea6b995be72a39e9f54abcd003a966cb /org.aspectj.ajdt.core
parent1f7d28f480f7f8c5e0316688a4f95abb62e7b747 (diff)
downloadaspectj-5c67166488df998bc208567c2fd27f21b52592c5.tar.gz
aspectj-5c67166488df998bc208567c2fd27f21b52592c5.zip
fix for Bugzilla Bug 51322
Introduce Unknown Type to class causes Null pointer exception
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java
index d5bf73da6..ef69dc022 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java
@@ -28,6 +28,7 @@ import org.eclipse.jdt.internal.compiler.flow.FlowInfo;
import org.eclipse.jdt.internal.compiler.flow.InitializationFlowContext;
import org.eclipse.jdt.internal.compiler.lookup.*;
import org.eclipse.jdt.internal.compiler.parser.Parser;
+import org.eclipse.jdt.internal.compiler.problem.AbortCompilation;
/**
* An inter-type method declaration.
@@ -101,6 +102,11 @@ public class InterTypeMethodDeclaration extends InterTypeDeclaration {
if (ignoreFurtherInvestigation) return null;
binding = classScope.referenceContext.binding.resolveTypesFor(binding);
+ if (binding == null) {
+ // if binding is null, we failed to find a type used in the method params, this error
+ // has already been reported.
+ throw new AbortCompilation();
+ }
ResolvedMember sig = new ResolvedMember(Member.METHOD, EclipseFactory.fromBinding(onTypeBinding),
declaredModifiers, EclipseFactory.fromBinding(binding.returnType), new String(declaredSelector),
EclipseFactory.fromBindings(binding.parameters),