aboutsummaryrefslogtreecommitdiffstats
path: root/weaver
diff options
context:
space:
mode:
authoraclement <aclement>2005-01-05 16:44:06 +0000
committeraclement <aclement>2005-01-05 16:44:06 +0000
commit14a2ae019e75aba654641183fbb20e3c05711975 (patch)
treec7b5f36b202662e4856fbba65e5e9232d38b174e /weaver
parent09464837f2fa6577ffba389e83c1c4a605d038ea (diff)
downloadaspectj-14a2ae019e75aba654641183fbb20e3c05711975.tar.gz
aspectj-14a2ae019e75aba654641183fbb20e3c05711975.zip
BWD: One extra check.
Diffstat (limited to 'weaver')
-rw-r--r--weaver/src/org/aspectj/weaver/patterns/DeclareParents.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/weaver/src/org/aspectj/weaver/patterns/DeclareParents.java b/weaver/src/org/aspectj/weaver/patterns/DeclareParents.java
index 3adcd722a..abb93d4b4 100644
--- a/weaver/src/org/aspectj/weaver/patterns/DeclareParents.java
+++ b/weaver/src/org/aspectj/weaver/patterns/DeclareParents.java
@@ -196,7 +196,8 @@ public class DeclareParents extends Declare {
return null;
}
-
+ if (parentType.isAssignableFrom(targetType)) return null; // already a parent
+
if (targetType.isAssignableFrom(parentType)) {
world.showMessage(IMessage.ERROR,
WeaverMessages.format(WeaverMessages.CANT_EXTEND_SELF,targetType.getName()),