提交 0daf1fa7 编写于 作者: K kizune

7154966: CRs found to be in Fixed state with no test and no noreg- keyword.

Reviewed-by: ksrini
上级 7c306817
/*
* @test /nodynamiccopyright/
* @bug 7090499
* @summary missing rawtypes warnings in anonymous inner class
* @compile/ref=T7090499.out -Xlint:rawtypes -XDrawDiagnostics T7090499.java
*/
class T7090499<X> {
{
new Object() {
T7090499 x;
};
}
}
T7090499.java:11:13: compiler.warn.raw.class.use: T7090499, T7090499<X>
1 warning
/*
* @test /nodynamiccopyright/
* @bug 7120463
* @summary Fix method reference parser support in order to avoid ambiguities
* @compile/fail/ref=T7120463.out -XDrawDiagnostics T7120463.java
*/
class T7120463 {
void test() { that(i < len, "oopmap"); }
void that(int i, String s) { };
}
T7120463.java:9:24: compiler.err.cant.resolve.location: kindname.variable, i, , , (compiler.misc.location: kindname.class, T7120463, null)
T7120463.java:9:28: compiler.err.cant.resolve.location: kindname.variable, len, , , (compiler.misc.location: kindname.class, T7120463, null)
2 errors
/*
* @test /nodynamiccopyright/
* @bug 7126754
* @summary Generics compilation failure casting List<? extends Set...> to List<Set...>
* @compile T7126754.java
*/
import java.util.List;
import java.util.Set;
public class T7126754 {
public static void main(String[] args) {
List<Set<? extends String>> a = null;
List<? extends Set<? extends String>> b = a;
List<? extends Set<? extends String>> c = null;
List<Set<? extends String>> d = (List<Set<? extends String>>)c;
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册