mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-07 13:39:36 +07:00
method refs: do not choose more specific method between methods with different number of params
(cherry picked from commit f986c7c3541f032da16736f43fd34c92337242c4)
This commit is contained in:
@@ -6,7 +6,7 @@ interface Func<TIn, TOut>{
|
||||
class Main {
|
||||
|
||||
public static void main(final String[] args) {
|
||||
Func<Integer, String> func = Integer::toString;
|
||||
<error descr="Incompatible types. Found: '<method reference>', required: 'Func<java.lang.Integer,java.lang.String>'">Func<Integer, String> func = Integer::toString;</error>
|
||||
System.out.println(func.run(6));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user