test/tools/javac/annotations/typeAnnotations/referenceinfos/Test.java

Thu, 10 Oct 2013 20:12:08 -0400

author
emc
date
Thu, 10 Oct 2013 20:12:08 -0400
changeset 2103
b1b4a6dcc282
parent 0
959103a6100f
permissions
-rw-r--r--

8008762: Type annotation on inner class in anonymous class show up as regular type annotations
8015257: type annotation with TYPE_USE and FIELD attributed differently if repeated.
8013409: test failures for type annotations
Summary: Fixes to address some problems in type annotations
Reviewed-by: jfranck, jjg

aoqi@0 1
aoqi@0 2 import java.util.*;
aoqi@0 3 import java.lang.annotation.*;
aoqi@0 4
aoqi@0 5 class Test<K> { GOuter<@TC Object, String> entrySet() { return null; } }
aoqi@0 6
aoqi@0 7 @interface A {}
aoqi@0 8 @interface B {}
aoqi@0 9 @interface C {}
aoqi@0 10 @interface D {}
aoqi@0 11 @interface E {}
aoqi@0 12 @interface F {}
aoqi@0 13
aoqi@0 14 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TA {}
aoqi@0 15 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TB {}
aoqi@0 16 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TC {}
aoqi@0 17 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TD {}
aoqi@0 18 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TE {}
aoqi@0 19 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TF {}
aoqi@0 20 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TG {}
aoqi@0 21 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TH {}
aoqi@0 22 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TI {}
aoqi@0 23 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TJ {}
aoqi@0 24 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TK {}
aoqi@0 25 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TL {}
aoqi@0 26 @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface TM {}
aoqi@0 27
aoqi@0 28 @Repeatable(RTAs.class) @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface RTA {}
aoqi@0 29 @Repeatable(RTBs.class) @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface RTB {}
aoqi@0 30 @ContainerFor(RTA.class) @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface RTAs { RTA[] value(); }
aoqi@0 31 @ContainerFor(RTB.class) @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) @interface RTBs { RTB[] value(); }
aoqi@0 32 @Target(value={ElementType.TYPE,ElementType.FIELD,ElementType.METHOD,ElementType.PARAMETER,ElementType.CONSTRUCTOR,ElementType.LOCAL_VARIABLE})
aoqi@0 33 @interface Decl {}

mercurial