diff options
-rw-r--r-- | tests/ajcTests.xml | 7 | ||||
-rw-r--r-- | tests/ajcTestsFailing.xml | 7 | ||||
-rw-r--r-- | weaver/src/org/aspectj/weaver/patterns/CflowPointcut.java | 11 |
3 files changed, 14 insertions, 11 deletions
diff --git a/tests/ajcTests.xml b/tests/ajcTests.xml index 788451035..0058ddf2c 100644 --- a/tests/ajcTests.xml +++ b/tests/ajcTests.xml @@ -6470,5 +6470,12 @@ <message kind="error" line="10"/> </compile> </ajc-test> + + <ajc-test dir="bugs" + pr="40876" + title="subtype-qualified pointcut reference"> + <compile files="PointcutLibraryTest.java"/> + <run class="PointcutLibraryTest"/> + </ajc-test> </suite> diff --git a/tests/ajcTestsFailing.xml b/tests/ajcTestsFailing.xml index 0f5af6454..2ac4c8bbe 100644 --- a/tests/ajcTestsFailing.xml +++ b/tests/ajcTestsFailing.xml @@ -5,13 +5,6 @@ <suite> <ajc-test dir="bugs" - pr="40876" - title="subtype-qualified pointcut reference"> - <compile files="PointcutLibraryTest.java"/> - <run class="PointcutLibraryTest"/> - </ajc-test> - - <ajc-test dir="bugs" pr="40858" comment="shouldn't super ref be permitted?" title="weaver trace on mis-qualified pointcut reference"> diff --git a/weaver/src/org/aspectj/weaver/patterns/CflowPointcut.java b/weaver/src/org/aspectj/weaver/patterns/CflowPointcut.java index 7345ecffa..3a0a8acf2 100644 --- a/weaver/src/org/aspectj/weaver/patterns/CflowPointcut.java +++ b/weaver/src/org/aspectj/weaver/patterns/CflowPointcut.java @@ -135,7 +135,9 @@ public class CflowPointcut extends Pointcut { Pointcut concreteEntry; - CrosscuttingMembers xcut = bindings.getConcreteAspect().crosscuttingMembers; + ResolvedTypeX concreteAspect = bindings.getConcreteAspect(); + + CrosscuttingMembers xcut = concreteAspect.crosscuttingMembers; Collection previousCflowEntries = xcut.getCflowEntries(); entryBindings.pushEnclosingDefinition(CFLOW_MARKER); @@ -150,17 +152,18 @@ public class CflowPointcut extends Pointcut { ResolvedMember cflowField = new ResolvedMember( - Member.FIELD, inAspect, Modifier.STATIC | Modifier.PUBLIC | Modifier.FINAL, + Member.FIELD, concreteAspect, Modifier.STATIC | Modifier.PUBLIC | Modifier.FINAL, NameMangler.cflowStack(xcut), TypeX.forName(NameMangler.CFLOW_STACK_TYPE).getSignature()); + //System.out.println("adding field to: " + inAspect + " field " + cflowField); // add field and initializer to inAspect //XXX and then that info above needs to be mapped down here to help with //XXX getting the exposed state right - bindings.getConcreteAspect().crosscuttingMembers.addConcreteShadowMunger( + concreteAspect.crosscuttingMembers.addConcreteShadowMunger( Advice.makeCflowEntry(world, concreteEntry, isBelow, cflowField, freeVars.length, innerCflowEntries)); - bindings.getConcreteAspect().crosscuttingMembers.addTypeMunger( + concreteAspect.crosscuttingMembers.addTypeMunger( world.makeCflowStackFieldAdder(cflowField)); |