testdata: ensure lambda can't be inferred from type parameter

This commit is contained in:
Anna Kozlova
2014-04-22 20:02:45 +02:00
parent 5b91054564
commit 7898108ccd
2 changed files with 17 additions and 0 deletions
@@ -0,0 +1,13 @@
class Test {
interface I {
void m();
}
<T> void call(T t) {}
<T extends Runnable> void call1(T t) {}
{
call<error descr="'call(T)' in 'Test' cannot be applied to '(<lambda expression>)'">(() -> {})</error>;
call1(() -> {});
}
}