From 9c8d91a03593d28e516294f4bc47e378a6149d10 Mon Sep 17 00:00:00 2001 From: aclement Date: Wed, 27 Oct 2010 16:06:28 +0000 Subject: 328840 --- tests/bugs1611/pr328840/Wibble.aj | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 tests/bugs1611/pr328840/Wibble.aj (limited to 'tests') diff --git a/tests/bugs1611/pr328840/Wibble.aj b/tests/bugs1611/pr328840/Wibble.aj new file mode 100644 index 000000000..11413e801 --- /dev/null +++ b/tests/bugs1611/pr328840/Wibble.aj @@ -0,0 +1,33 @@ +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; + + +public aspect Wibble { + + declare @field: (@III *) Song.*: @Foo; + + before(): get((@III *) Song.*) { + System.out.println(); + } + public static void main(String []argv) throws Exception { + System.out.println(Song.class.getDeclaredField("i").getAnnotation(Foo.class)); + } +} + +@III +class XX { + +} +class Song { + + XX i; + + void foo() { + System.out.println(i); + } +} + +@Retention(RetentionPolicy.RUNTIME) +@interface III {} +@Retention(RetentionPolicy.RUNTIME) +@interface Foo {} -- cgit v1.2.3