mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-03 15:50:52 +07:00
overload resolution: erase type of parameter when site substitutor is raw (IDEA-203450)
similar to erasure of call type when inferred substitutor is raw
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
class TestCaller1<P1> {
|
||||
{
|
||||
TestCaller1.foo(null);
|
||||
}
|
||||
public static void foo(HashSet<Integer> fn) { }
|
||||
public <P> void foo(Set<String> fn) { }
|
||||
}
|
||||
|
||||
class TestCaller2 {
|
||||
{
|
||||
TestCaller2.foo<error descr="Ambiguous method call: both 'TestCaller2.foo(HashSet<Integer>)' and 'TestCaller2.foo(Set<String>)' match">(null)</error>;
|
||||
}
|
||||
public static void foo(HashSet<Integer> fn) { }
|
||||
public <P> void foo(Set<String> fn) { }
|
||||
}
|
||||
|
||||
class TestCaller3 {
|
||||
{
|
||||
TestCaller2.foo<error descr="Ambiguous method call: both 'TestCaller2.foo(HashSet<Integer>)' and 'TestCaller2.foo(Set<String>)' match">(null)</error>;
|
||||
}
|
||||
public static void foo(HashSet<Integer> fn) { }
|
||||
public static void foo(Set<String> fn) { }
|
||||
}
|
||||
Reference in New Issue
Block a user