]> source.dussan.org Git - aspectj.git/commitdiff
fix for120521
authoraclement <aclement>
Tue, 13 Dec 2005 11:32:58 +0000 (11:32 +0000)
committeraclement <aclement>
Tue, 13 Dec 2005 11:32:58 +0000 (11:32 +0000)
tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java
weaver/src/org/aspectj/weaver/ResolvedType.java

index dfc65f8606372b4c029baf55d5ce1363b4e4d602..1ff229944be8bbb0dff3ac92bf706f0a939bc591 100644 (file)
@@ -41,7 +41,7 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
   protected File getSpecFile() {
     return new File("../tests/src/org/aspectj/systemtest/ajc150/ajc150.xml");
   }
-  //public void testNamedPointcutPertarget_pr120521() { runTest("named pointcut not resolved in pertarget pointcut");}
+  public void testNamedPointcutPertarget_pr120521() { runTest("named pointcut not resolved in pertarget pointcut");}
   public void testDollarClasses_pr120474() { runTest("Dollar classes");}
   public void testGenericPTW_pr119539_1() { runTest("generic pertypewithin aspect - 1");}
   public void testGenericPTW_pr119539_2() { runTest("generic pertypewithin aspect - 2");}
index 524e2a25ff9592792ae6507457f20ea4b837ccfe..d16b041c241479b395d4ad0e1567abc01f244fa2 100644 (file)
@@ -480,6 +480,12 @@ public abstract class ResolvedType extends UnresolvedType implements AnnotatedEl
                 return f;
             }
         }
+        // pr120521
+        if (!getOutermostType().equals(this)) {
+               ResolvedType outerType = getOutermostType().resolve(world);
+               ResolvedPointcutDefinition rpd = outerType.findPointcut(name);
+               return rpd;
+        }
         return null; // should we throw an exception here?
     }