test/tools/javac/generics/6946618/T6946618c.java

Tue, 13 Sep 2011 14:14:57 +0100

author
mcimadamore
date
Tue, 13 Sep 2011 14:14:57 +0100
changeset 1085
ed338593b0b6
parent 598
064468702a8d
child 2525
2eb010b6cb22
permissions
-rw-r--r--

7086595: Error message bug: name of initializer is 'null'
Summary: Implementation of MethodSymbol.location() should take into account static/instance initializers
Reviewed-by: jjg

mcimadamore@562 1 /*
mcimadamore@562 2 * @test /nodynamiccopyright/
jjg@598 3 * @bug 6946618 6968497
mcimadamore@562 4 * @summary sqe test fails: javac/generics/NewOnTypeParm in pit jdk7 b91 in all platforms.
mcimadamore@562 5 * @author mcimadamore
mcimadamore@562 6 * @compile/fail/ref=T6946618c.out -XDrawDiagnostics T6946618c.java
mcimadamore@562 7 */
mcimadamore@562 8
mcimadamore@562 9 class T6946618c {
mcimadamore@562 10 static class C<T> { }
mcimadamore@562 11
mcimadamore@562 12 void test() {
mcimadamore@562 13 C<?> c1 = new C<? extends String>();
mcimadamore@562 14 C<?> c2 = new C<? super String>();
mcimadamore@562 15 C<?> c3 = new C<?>();
mcimadamore@562 16 }
mcimadamore@562 17 }

mercurial