1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/test/tools/javac/lambda/funcInterfaces/LambdaTest2_neg1.java Wed Apr 27 01:34:52 2016 +0800 1.3 @@ -0,0 +1,19 @@ 1.4 +/* 1.5 + * @test /nodynamiccopyright/ 1.6 + * @bug 8003280 1.7 + * @summary Add lambda tests 1.8 + * This test is for identifying SAM types #5 and instantiating non-SAM types #7 through inner class, 1.9 + see Helper.java for SAM types 1.10 + * @compile/fail/ref=LambdaTest2_neg1.out -XDrawDiagnostics LambdaTest2_neg1.java Helper.java 1.11 + */ 1.12 + 1.13 +public class LambdaTest2_neg1 { 1.14 + 1.15 + public static void main(String[] args) { 1.16 + LambdaTest2_neg1 test = new LambdaTest2_neg1(); 1.17 + //not convertible - QooRoo is not a SAM 1.18 + test.methodQooRoo((Integer i) -> { }); 1.19 + } 1.20 + 1.21 + void methodQooRoo(QooRoo<Integer, Integer, Void> qooroo) { } 1.22 +}