diff options
author | aclement <aclement> | 2005-07-04 14:52:51 +0000 |
---|---|---|
committer | aclement <aclement> | 2005-07-04 14:52:51 +0000 |
commit | 7b05949f6325a37a74ee81f25ae79be3fdf0ac9f (patch) | |
tree | 90673d6824b5c39821ed005152945ba9548a0f06 /org.aspectj.ajdt.core | |
parent | 5b720958877af161fb425065f68e940236cf08ae (diff) | |
download | aspectj-7b05949f6325a37a74ee81f25ae79be3fdf0ac9f.tar.gz aspectj-7b05949f6325a37a74ee81f25ae79be3fdf0ac9f.zip |
generics: comments added to indicate whats gone wrong *should* there be an NPE at a particular line... TODO left in so we can look to remove it later if it doesnt cause problems when generics is complete.
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r-- | org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/AjLookupEnvironment.java | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/AjLookupEnvironment.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/AjLookupEnvironment.java index 9578f68fc..70d378ab2 100644 --- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/AjLookupEnvironment.java +++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/AjLookupEnvironment.java @@ -578,7 +578,15 @@ public class AjLookupEnvironment extends LookupEnvironment { // Get the annotation specified in the declare TypeBinding tb = factory.makeTypeBinding(decA.getAspect()); - MethodBinding[] mbs = ((SourceTypeBinding)tb).getMethods(decA.getAnnotationMethod().toCharArray()); + + SourceTypeBinding stb = null; + // TODO asc determine if there really is a problem here (see comment below) + + // ClassCastException here means we probably have either a parameterized type or a raw type, we need the + // commented out code to get it to work ... currently uncommented because I've not seen a case where its + // required yet ... + stb = (SourceTypeBinding)tb; + MethodBinding[] mbs = stb.getMethods(decA.getAnnotationMethod().toCharArray()); long abits = mbs[0].getAnnotationTagBits(); // ensure resolved TypeDeclaration typeDecl = ((SourceTypeBinding)mbs[0].declaringClass).scope.referenceContext; AbstractMethodDeclaration methodDecl = typeDecl.declarationOf(mbs[0]); |