Redundant nullable return type: false negative with return expression in local function or lambda

#KT-41817 Fixed
This commit is contained in:
Toshiaki Kameyama
2020-09-11 10:22:32 +09:00
committed by Vladimir Dolzhenko
parent de3907e8cc
commit 370622087b
6 changed files with 42 additions and 3 deletions
@@ -8249,6 +8249,16 @@ public class LocalInspectionTestGenerated extends AbstractLocalInspectionTest {
runTest("idea/testData/inspectionsLocal/redundantNullableReturnType/function/overridable.kt");
}
@TestMetadata("returnNullableForLambda.kt")
public void testReturnNullableForLambda() throws Exception {
runTest("idea/testData/inspectionsLocal/redundantNullableReturnType/function/returnNullableForLambda.kt");
}
@TestMetadata("returnNullableForLocalFunction.kt")
public void testReturnNullableForLocalFunction() throws Exception {
runTest("idea/testData/inspectionsLocal/redundantNullableReturnType/function/returnNullableForLocalFunction.kt");
}
@TestMetadata("returnNullableFromLambdaInBlockBody.kt")
public void testReturnNullableFromLambdaInBlockBody() throws Exception {
runTest("idea/testData/inspectionsLocal/redundantNullableReturnType/function/returnNullableFromLambdaInBlockBody.kt");