aboutsummaryrefslogtreecommitdiffstats
path: root/weaver
diff options
context:
space:
mode:
authoraclement <aclement>2006-07-28 10:22:45 +0000
committeraclement <aclement>2006-07-28 10:22:45 +0000
commit2f3145681eb99bf4a32461a366ab87f1108bd056 (patch)
tree714daa04d859b17340869477f7d89699a26fd58c /weaver
parentc8497181b172eaf282a239e21785fcc40b81033a (diff)
downloadaspectj-2f3145681eb99bf4a32461a366ab87f1108bd056.tar.gz
aspectj-2f3145681eb99bf4a32461a366ab87f1108bd056.zip
pipeline changes: changed adviceDidNotMatch processing and moved reweavable message (dont want it for every file woven!)
Diffstat (limited to 'weaver')
-rw-r--r--weaver/src/org/aspectj/weaver/bcel/BcelWeaver.java22
1 files changed, 14 insertions, 8 deletions
diff --git a/weaver/src/org/aspectj/weaver/bcel/BcelWeaver.java b/weaver/src/org/aspectj/weaver/bcel/BcelWeaver.java
index b38f470e9..feae53d0f 100644
--- a/weaver/src/org/aspectj/weaver/bcel/BcelWeaver.java
+++ b/weaver/src/org/aspectj/weaver/bcel/BcelWeaver.java
@@ -499,7 +499,12 @@ public class BcelWeaver implements IWeaver {
return (sm2.getSourceLocation().getOffset()-sm1.getSourceLocation().getOffset());
}
});
-
+
+ if (inReweavableMode)
+ world.showMessage(IMessage.INFO,
+ WeaverMessages.format(WeaverMessages.REWEAVABLE_MODE),
+ null, null);
+
if (trace.isTraceEnabled()) trace.exit("prepareForWeave");
}
@@ -1136,6 +1141,8 @@ public class BcelWeaver implements IWeaver {
// bug 119882 - see above comment for bug 113531
ReferenceTypeDelegate theDelegate = ((ReferenceType)theType).getDelegate();
+
+ // TODO urgh - put a method on the interface to check this, string compare is hideous
if (theDelegate.getClass().getName().endsWith("EclipseSourceType")) continue;
throw new BCException("Can't find bcel delegate for "+className+" type="+theType.getClass());
@@ -1150,13 +1157,15 @@ public class BcelWeaver implements IWeaver {
deletedTypenames = new ArrayList();
- warnOnUnmatchedAdvice();
-
requestor.weaveCompleted();
CompilationAndWeavingContext.leavingPhase(weaveToken);
if (trace.isTraceEnabled()) trace.exit("weave",wovenClassNames);
return wovenClassNames;
}
+
+ public void allWeavingComplete() {
+ warnOnUnmatchedAdvice();
+ }
/**
* In 1.5 mode and with XLint:adviceDidNotMatch enabled, put out messages for any
@@ -1213,7 +1222,8 @@ public class BcelWeaver implements IWeaver {
if (!(ba.getSignature() instanceof BcelMethod)
|| !Utility.isSuppressing((AnnotationX[])ba.getSignature().getAnnotations(),"adviceDidNotMatch")) {
- world.getLint().adviceDidNotMatch.signal(ba.getDeclaringAspect().toString(),element.getSourceLocation());
+ world.getLint().adviceDidNotMatch.signal(ba.getDeclaringAspect().toString(),
+ new SourceLocation(element.getSourceLocation().getSourceFile(),element.getSourceLocation().getLine()));//element.getSourceLocation());
}
}
}
@@ -1257,10 +1267,6 @@ public class BcelWeaver implements IWeaver {
}
public void prepareToProcessReweavableState() {
- if (inReweavableMode)
- world.showMessage(IMessage.INFO,
- WeaverMessages.format(WeaverMessages.REWEAVABLE_MODE),
- null, null);
}
public void processReweavableStateIfPresent(String className, BcelObjectType classType) {