summaryrefslogtreecommitdiffstats
path: root/org.aspectj.ajdt.core
diff options
context:
space:
mode:
authoraclement <aclement>2005-10-20 10:32:20 +0000
committeraclement <aclement>2005-10-20 10:32:20 +0000
commit720a6d9d5c1900b79a91d704af8c3973f6165e0d (patch)
tree3c1d187b35205707b2f61557445cbde4cb206692 /org.aspectj.ajdt.core
parenta07fd2951422464096ce02a682e8d02be17353ff (diff)
downloadaspectj-720a6d9d5c1900b79a91d704af8c3973f6165e0d.tar.gz
aspectj-720a6d9d5c1900b79a91d704af8c3973f6165e0d.zip
Fix for ordering problem when using generic abstract aspects. Fix for crappy code (of mine) in ResolvedType.discover... - see pr112105 comment #10
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/AjLookupEnvironment.java13
1 files changed, 11 insertions, 2 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 58e650286..c3756aec0 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
@@ -47,6 +47,7 @@ import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.LocalTypeBinding;
import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment;
import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.MethodBinding;
import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.PackageBinding;
+import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.ParameterizedTypeBinding;
import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding;
import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.SourceTypeBinding;
import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.TagBits;
@@ -251,8 +252,16 @@ public class AjLookupEnvironment extends LookupEnvironment implements AnonymousC
// Look at the supertype first
ContextToken tok = CompilationAndWeavingContext.enteringPhase(CompilationAndWeavingContext.COLLECTING_ITDS_AND_DECLARES, sourceType.sourceName);
ReferenceBinding superType = sourceType.superclass();
- if (yetToProcess.contains(superType) && superType instanceof SourceTypeBinding) {
- collectAllITDsAndDeclares((SourceTypeBinding)superType, yetToProcess);
+ if (superType instanceof SourceTypeBinding) {
+ if (yetToProcess.contains(superType)) {
+ collectAllITDsAndDeclares((SourceTypeBinding)superType, yetToProcess);
+ }
+ } else if (superType instanceof ParameterizedTypeBinding) {
+ // If its a PTB we need to pull the SourceTypeBinding out of it.
+ ParameterizedTypeBinding ptb = (ParameterizedTypeBinding)superType;
+ if (ptb.type instanceof SourceTypeBinding && yetToProcess.contains(ptb.type)) {
+ collectAllITDsAndDeclares((SourceTypeBinding)ptb.type, yetToProcess);
+ }
}
buildInterTypeAndPerClause(sourceType.scope);
addCrosscuttingStructures(sourceType.scope);