diff options
author | avasseur <avasseur> | 2005-10-21 13:18:55 +0000 |
---|---|---|
committer | avasseur <avasseur> | 2005-10-21 13:18:55 +0000 |
commit | 5e17799ef005829b992198048e4b18abff288f78 (patch) | |
tree | 71b138a53ce6355bca38a6a2cad941b72b1ed7e3 | |
parent | 62a4476ca3ff54a75a1b435d8dfe49a0e29cbdc6 (diff) | |
download | aspectj-5e17799ef005829b992198048e4b18abff288f78.tar.gz aspectj-5e17799ef005829b992198048e4b18abff288f78.zip |
weaveinfo for @AJ ITD
3 files changed, 20 insertions, 4 deletions
diff --git a/tests/src/org/aspectj/systemtest/ajc150/ataspectj/syntax.xml b/tests/src/org/aspectj/systemtest/ajc150/ataspectj/syntax.xml index 89f2e0f08..cf6c106b0 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/ataspectj/syntax.xml +++ b/tests/src/org/aspectj/systemtest/ajc150/ataspectj/syntax.xml @@ -150,12 +150,19 @@ </ajc-test> <ajc-test dir="java5/ataspectj" title="DeclareParentsInterface"> - <compile files="ataspectj/DeclareParentsInterfaceTest.java,ataspectj/TestHelper.java" options="-1.5 -Xdev:NoAtAspectJProcessing -Xlint:ignore"/> + <compile files="ataspectj/DeclareParentsInterfaceTest.java,ataspectj/TestHelper.java" options="-showWeaveInfo -1.5 -Xdev:NoAtAspectJProcessing -Xlint:ignore"> + <message kind="weave" text="Extending interface set for type 'ataspectj.DeclareParentsInterfaceTest$Target' (DeclareParentsInterfaceTest.java) to include 'ataspectj.DeclareParentsInterfaceTest$Marker' (DeclareParentsInterfaceTest.java)"/> + <message kind="weave" text="Join point "/> + </compile> <run class="ataspectj.DeclareParentsInterfaceTest"/> </ajc-test> <ajc-test dir="java5/ataspectj" title="DeclareParentsImplements"> - <compile files="ataspectj/DeclareParentsImplementsTest.java,ataspectj/TestHelper.java" options="-1.5 -Xdev:NoAtAspectJProcessing -Xlint:ignore"/> + <compile files="ataspectj/DeclareParentsImplementsTest.java,ataspectj/TestHelper.java" options="-showWeaveInfo -1.5 -Xdev:NoAtAspectJProcessing -Xlint:ignore"> + <message kind="weave" text="Join point "/> + <message kind="weave" text="Extending interface set for type 'ataspectj.DeclareParentsImplementsTest$Target' (DeclareParentsImplementsTest.java) to include 'ataspectj.DeclareParentsImplementsTest$Introduced' (DeclareParentsImplementsTest.java)"/> + <message kind="weave" text="Type 'ataspectj.DeclareParentsImplementsTest$Target' (DeclareParentsImplementsTest.java) has intertyped method from 'ataspectj.DeclareParentsImplementsTest$TestAspect' (DeclareParentsImplementsTest.java:'void ataspectj.DeclareParentsImplementsTest$Introduced.intro()')"/> + </compile> <run class="ataspectj.DeclareParentsImplementsTest"/> </ajc-test> diff --git a/weaver/src/org/aspectj/weaver/MethodDelegateTypeMunger.java b/weaver/src/org/aspectj/weaver/MethodDelegateTypeMunger.java index 26ae5b21d..e7bc20d3b 100644 --- a/weaver/src/org/aspectj/weaver/MethodDelegateTypeMunger.java +++ b/weaver/src/org/aspectj/weaver/MethodDelegateTypeMunger.java @@ -58,7 +58,7 @@ public class MethodDelegateTypeMunger extends ResolvedTypeMunger { break; } } - if (field == null) { + if (field == null) { throw new RuntimeException("Should not happen: aspect field not found for @DeclareParents delegate"); } else { aspectFieldDelegate = field; diff --git a/weaver/src/org/aspectj/weaver/ResolvedTypeMunger.java b/weaver/src/org/aspectj/weaver/ResolvedTypeMunger.java index 1389d78c6..7717915f1 100644 --- a/weaver/src/org/aspectj/weaver/ResolvedTypeMunger.java +++ b/weaver/src/org/aspectj/weaver/ResolvedTypeMunger.java @@ -243,7 +243,16 @@ public abstract class ResolvedTypeMunger { } throw new BCException("bad kind: " + key); } - } + + public String toString() { + // we want MethodDelegate to appear as Method in WeaveInfo messages + if (MethodDelegate.getName().equals(getName())) { + return Method.toString(); + } else { + return super.toString(); + } + } + } // ---- fields |