1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/test/tools/javac/lambda/TargetType40.java Wed Apr 27 01:34:52 2016 +0800 1.3 @@ -0,0 +1,18 @@ 1.4 +/* 1.5 + * @test /nodynamiccopyright/ 1.6 + * @bug 8003280 1.7 + * @summary Add lambda tests 1.8 + * compiler silently crashes when void method is passed as argument in overloaded call site 1.9 + * @compile/fail/ref=TargetType40.out -XDrawDiagnostics TargetType40.java 1.10 + */ 1.11 + 1.12 +class TargetType40 { 1.13 + void m(String s) { } 1.14 + void m(Integer i) { } 1.15 + 1.16 + void void_method() {} 1.17 + 1.18 + void test() { 1.19 + m(void_method()); 1.20 + } 1.21 +}