diff options
-rw-r--r-- | org.eclipse.jdt.core/jdtcore-for-aspectj-src.zip | bin | 3832332 -> 3813341 bytes | |||
-rw-r--r-- | org.eclipse.jdt.core/jdtcore-for-aspectj.jar | bin | 4279739 -> 4279581 bytes | |||
-rw-r--r-- | tests/bugs/PR61572.aj | 44 |
3 files changed, 44 insertions, 0 deletions
diff --git a/org.eclipse.jdt.core/jdtcore-for-aspectj-src.zip b/org.eclipse.jdt.core/jdtcore-for-aspectj-src.zip Binary files differindex 98dfa8800..34c57f137 100644 --- a/org.eclipse.jdt.core/jdtcore-for-aspectj-src.zip +++ b/org.eclipse.jdt.core/jdtcore-for-aspectj-src.zip diff --git a/org.eclipse.jdt.core/jdtcore-for-aspectj.jar b/org.eclipse.jdt.core/jdtcore-for-aspectj.jar Binary files differindex c0d1e166b..e0e8c9701 100644 --- a/org.eclipse.jdt.core/jdtcore-for-aspectj.jar +++ b/org.eclipse.jdt.core/jdtcore-for-aspectj.jar diff --git a/tests/bugs/PR61572.aj b/tests/bugs/PR61572.aj new file mode 100644 index 000000000..0f29c1303 --- /dev/null +++ b/tests/bugs/PR61572.aj @@ -0,0 +1,44 @@ +/* intertype method declarations should be a static context; +it is incorrect to refer to instance variables of the +originating aspect. ajc fails to check this properly when +an ITD method is applied to an inner class. + +The example below compiles fine, but then throws + +java.lang.NoSuchFieldError: zzz + +when run. + +*/ + +aspect NewFoo { + + int zzz = 3; + + public void Aaa.Ccc.bar() { + System.out.println(zzz); // CE L19: illegal reference to zzz + } +} + +class Aaa { + + public class Ccc { + + } + + public Ccc ccc; + + public Aaa() { + ccc = new Ccc(); + } +} + +class IllegalRef { + + + public static void main(String[] args) { + Aaa aaa = new Aaa(); + aaa.ccc.bar(); + } + +}
\ No newline at end of file |