test/tools/javac/annotations/6881115/T6881115.java

Sat, 17 Nov 2012 19:01:03 +0000

author
mcimadamore
date
Sat, 17 Nov 2012 19:01:03 +0000
changeset 1415
01c9d4161882
parent 722
4851ff2ffc10
child 1521
71f35e4b93a5
permissions
-rw-r--r--

8003280: Add lambda tests
Summary: Turn on lambda expression, method reference and default method support
Reviewed-by: jjg

mcimadamore@629 1 /*
mcimadamore@629 2 * @test /nodynamiccopyright/
mcimadamore@634 3 * @bug 6881115 6976649
mcimadamore@629 4 * @summary javac permits nested anno w/o mandatory attrs => IncompleteAnnotationException
mcimadamore@629 5 * @author mcimadamore
mcimadamore@629 6 * @compile/fail/ref=T6881115.out -XDrawDiagnostics T6881115.java
mcimadamore@629 7 */
mcimadamore@629 8
mcimadamore@629 9 @interface A {
mcimadamore@629 10 B b() default @B(b2 = 1, b2 = 2);
mcimadamore@629 11 B[] b_arr() default {@B(), @B(b2 = 1, b2 = 2)};
mcimadamore@629 12 }
mcimadamore@629 13 @interface B {
mcimadamore@629 14 String b1();
mcimadamore@629 15 int b2();
mcimadamore@629 16 }
mcimadamore@634 17 @A(b = @B(b2 = 1, b2 = 2),
mcimadamore@634 18 b_arr = {@B(), @B(b2 = 1, b2 = 2)})
jjg@722 19 class T6881115</*308 @A(b = @B(b2 = 1, b2 = 2),
jjg@722 20 b_arr = {@B(), @B(b2 = 1, b2 = 2)})*/ X> {}

mercurial