aboutsummaryrefslogtreecommitdiffstats
path: root/org.aspectj.matcher
diff options
context:
space:
mode:
authorAndy Clement <andrew.clement@gmail.com>2013-04-01 14:34:25 -0700
committerAndy Clement <andrew.clement@gmail.com>2013-04-01 14:34:25 -0700
commit99414d4203fc52b93dfa8ecb69211766609137ad (patch)
tree22f560022a2bd577bef7b2bc9c07cebf1c2ec0a1 /org.aspectj.matcher
parent1afe1016d04389da4918b3d91f0d8125183dd040 (diff)
downloadaspectj-99414d4203fc52b93dfa8ecb69211766609137ad.tar.gz
aspectj-99414d4203fc52b93dfa8ecb69211766609137ad.zip
Fix for 404601
Added 1.7.3 test suite
Diffstat (limited to 'org.aspectj.matcher')
-rw-r--r--org.aspectj.matcher/src/org/aspectj/weaver/ResolvedType.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/org.aspectj.matcher/src/org/aspectj/weaver/ResolvedType.java b/org.aspectj.matcher/src/org/aspectj/weaver/ResolvedType.java
index b9fe12a3e..0eaee3758 100644
--- a/org.aspectj.matcher/src/org/aspectj/weaver/ResolvedType.java
+++ b/org.aspectj.matcher/src/org/aspectj/weaver/ResolvedType.java
@@ -1858,6 +1858,17 @@ public abstract class ResolvedType extends UnresolvedType implements AnnotatedEl
int c = compareMemberPrecedence(typeTransformerSignature, existingMember);
// System.err.println(" c: " + c);
if (c < 0) {
+ ResolvedType typeTransformerTargetType = typeTransformerSignature.getDeclaringType().resolve(world);
+ if (typeTransformerTargetType.isInterface()) {
+ ResolvedType existingMemberType = existingMember.getDeclaringType().resolve(world);
+ if ((rtm instanceof NewMethodTypeMunger) && !typeTransformerTargetType.equals(existingMemberType)) {
+ // Might be pr404601. ITD is on an interface with a different visibility to the real member
+ if (Modifier.isPrivate(typeTransformerSignature.getModifiers()) &&
+ Modifier.isPublic(existingMember.getModifiers())) {
+ world.getMessageHandler().handleMessage(new Message("private intertype declaration '"+typeTransformerSignature.toString()+"' clashes with public member '"+existingMember.toString()+"'",existingMember.getSourceLocation(),true));
+ }
+ }
+ }
// existingMember dominates munger
checkLegalOverride(typeTransformerSignature, existingMember, 0x10, typeTransformer.getAspectType());
return true;