1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/test/tools/javac/lambda/TargetType10.java Sat Nov 17 19:01:03 2012 +0000 1.3 @@ -0,0 +1,19 @@ 1.4 +/* 1.5 + * @test /nodynamiccopyright/ 1.6 + * @bug 8003280 1.7 + * @summary Add lambda tests 1.8 + * check that wildcards in the target method of a lambda conversion is handled correctly 1.9 + * @author Maurizio Cimadamore 1.10 + * @compile/fail/ref=TargetType10.out -XDrawDiagnostics TargetType10.java 1.11 + */ 1.12 + 1.13 +class TargetType10 { 1.14 + interface Function<A,R> { 1.15 + R apply(A a); 1.16 + } 1.17 + 1.18 + static class Test { 1.19 + <A,B,C> Function<A,C> compose(Function<B,C> g, Function<A,? extends B> f) { return null; } 1.20 + { compose(x -> "a" + x, x -> x + "b"); } 1.21 + } 1.22 +}