Maurizio Cimadamore a494f0ab86 8003280: Add lambda tests
Turn on lambda expression, method reference and default method support

Reviewed-by: jjg
2012-11-17 19:01:03 +00:00

19 lines
388 B
Java

/*
* @test /nodynamiccopyright/
* @bug 8003280
* @summary Add lambda tests
* Test that lambda conversion is only for SAM interface, not abstract class
* @compile/fail/ref=AbstractClass_neg.out -XDrawDiagnostics AbstractClass_neg.java
*/
public class AbstractClass_neg {
abstract class SAM {
abstract int m();
}
void test() {
SAM s = ()-> 6;
}
}