diff options
author | aclement <aclement> | 2006-06-25 19:24:11 +0000 |
---|---|---|
committer | aclement <aclement> | 2006-06-25 19:24:11 +0000 |
commit | be2aca6940a820f96cfc4a6deeb7d4be5bba767d (patch) | |
tree | 27c284c2b2aebd718f3ecb092b41b18af66aabf0 /org.aspectj.ajdt.core/src | |
parent | 5e24c70a7b30ae065ab83b1cb4e5f3c17a39c290 (diff) | |
download | aspectj-be2aca6940a820f96cfc4a6deeb7d4be5bba767d.tar.gz aspectj-be2aca6940a820f96cfc4a6deeb7d4be5bba767d.zip |
recognizes parameterized methods (fix for 148545)
Diffstat (limited to 'org.aspectj.ajdt.core/src')
-rw-r--r-- | org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/PrivilegedHandler.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/PrivilegedHandler.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/PrivilegedHandler.java index d9ac33d43..5bc5c1a2f 100644 --- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/PrivilegedHandler.java +++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/PrivilegedHandler.java @@ -33,6 +33,7 @@ import org.aspectj.org.eclipse.jdt.internal.compiler.ast.ASTNode; import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.FieldBinding; import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.IPrivilegedHandler; import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.MethodBinding; +import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.ParameterizedMethodBinding; import org.aspectj.org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding; @@ -57,7 +58,13 @@ public class PrivilegedHandler implements IPrivilegedHandler { public MethodBinding getPrivilegedAccessMethod(MethodBinding baseMethod, ASTNode location) { if (baseMethod.alwaysNeedsAccessMethod()) return baseMethod; - ResolvedMember key = inAspect.factory.makeResolvedMember(baseMethod); + ResolvedMember key = null; + + if (baseMethod instanceof ParameterizedMethodBinding) { + key = inAspect.factory.makeResolvedMember(((ParameterizedMethodBinding)baseMethod).original()); + } else { + key = inAspect.factory.makeResolvedMember(baseMethod); + } if (accessors.containsKey(key)) return (MethodBinding)accessors.get(key); MethodBinding ret; |