Files
openide/java/java-tests/testData/codeInsight/daemonCodeAnalyzer/lambda/methodRef/ExactReferencesToArrayCreation.java
anna 23432e3cd7 new inference: array constructor refs are always exact (IDEA-115725)
(cherry picked from commit 0f6538fc54bbee0aaf6cbab9884c0407937d4568)
2013-11-25 16:47:36 +01:00

14 lines
419 B
Java

public class InspectorTest {
interface Stream<T> {
<A> A[] toArray(IntFunction<A[]> generator);
}
interface IntFunction<R> {
R apply(int value);
}
public static void main(Stream<Object> objectStream){
varargMethod(String[]::new,
objectStream.toArray(String[]::new));
}
public static <T> void varargMethod(IntFunction<T[]> generator,T[]... a){}
}