mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 00:11:26 +07:00
constructor refs: forbid raw constructor references with explicit new type args
(cherry picked from commit a127d801aa080f2efe3784edd5cca419dccfda2e)
This commit is contained in:
+13
@@ -0,0 +1,13 @@
|
||||
class Test {
|
||||
interface I {
|
||||
Object _();
|
||||
}
|
||||
static class Foo<X> {}
|
||||
static class Foo1 {}
|
||||
void testAssign() {
|
||||
I o = <error descr="Raw constructor reference with explicit type parameters for constructor">Foo::<String>new</error>;
|
||||
I o1 = Foo1::<String>new;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user