return statements inside lambda: extract method return type fixed (IDEA-133095)

This commit is contained in:
Anna Kozlova
2014-11-18 19:37:57 +01:00
parent 2817b5e184
commit 9d9caf9620
4 changed files with 30 additions and 1 deletions
@@ -0,0 +1,10 @@
class Test {
interface I {
String foo();
}
public void foo(int ii) {
I r = () -> {
<selection>return "42";</selection>
};
}
}
@@ -0,0 +1,14 @@
class Test {
interface I {
String foo();
}
public void foo(int ii) {
I r = () -> {
return newMethod();
};
}
private String newMethod() {
return "42";
}
}