summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoraclement <aclement>2005-07-18 08:44:04 +0000
committeraclement <aclement>2005-07-18 08:44:04 +0000
commit28c116d4771fd24f5298e7353fa68335e0f09a90 (patch)
tree04bb446c797708e16e574595d6e5534db4fa24af
parente15794a2aa3c981571d54ff370c6e4f1d9ee97b1 (diff)
downloadaspectj-28c116d4771fd24f5298e7353fa68335e0f09a90.tar.gz
aspectj-28c116d4771fd24f5298e7353fa68335e0f09a90.zip
First bits of fix for pr98901 (annotation copying)
-rw-r--r--weaver/src/org/aspectj/weaver/AjcMemberMaker.java11
-rw-r--r--weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java5
2 files changed, 12 insertions, 4 deletions
diff --git a/weaver/src/org/aspectj/weaver/AjcMemberMaker.java b/weaver/src/org/aspectj/weaver/AjcMemberMaker.java
index 4ef65ba88..798864ff1 100644
--- a/weaver/src/org/aspectj/weaver/AjcMemberMaker.java
+++ b/weaver/src/org/aspectj/weaver/AjcMemberMaker.java
@@ -605,8 +605,9 @@ public class AjcMemberMaker {
/**
- * This method goes on the target type of the inter-type method. (and possibly the topmost-implemeters,
- * if the target type is an interface)
+ * This method goes on the target type of the inter-type method. (and possibly the topmost-implementors,
+ * if the target type is an interface). The implementation will call the interMethodDispatch method on the
+ * aspect.
*/
public static ResolvedMember interMethod(ResolvedMember meth, UnresolvedType aspectType, boolean onInterface)
{
@@ -623,7 +624,8 @@ public class AjcMemberMaker {
}
/**
- * This static method goes on the declaring aspect of the inter-type method.
+ * This static method goes on the declaring aspect of the inter-type method. The implementation
+ * calls the interMethodBody() method on the aspect.
*/
public static ResolvedMember interMethodDispatcher(ResolvedMember meth, UnresolvedType aspectType)
{
@@ -639,7 +641,8 @@ public class AjcMemberMaker {
}
/**
- * This static method goes on the declaring aspect of the inter-type method.
+ * This method goes on the declaring aspect of the inter-type method.
+ * It contains the real body of the ITD method.
*/
public static ResolvedMember interMethodBody(ResolvedMember meth, UnresolvedType aspectType)
{
diff --git a/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java b/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java
index 7fd5311bb..f791f567a 100644
--- a/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java
+++ b/weaver/src/org/aspectj/weaver/bcel/LazyClassGen.java
@@ -972,6 +972,11 @@ public final class LazyClassGen {
myGen.addField(field);
}
+ public void replaceField(Field oldF, Field newF){
+ myGen.removeField(oldF);
+ myGen.addField(newF);
+ }
+
public void addField(Field field, ISourceLocation sourceLocation) {
addField(field);
if (!(field.isPrivate()