redundant lambda code block: warn for self suppressions so it would be suppressed by LocalInspectionPass

otherwise Redundant Suppression would report such cases as suppress comment would prevent reporting by itself
This commit is contained in:
Anna.Kozlova
2018-09-26 17:51:41 +02:00
parent 718ec4eef7
commit 01eb8ca66b
3 changed files with 36 additions and 3 deletions
@@ -0,0 +1,19 @@
// "Remove 'CodeBlock2Expr' suppression" "false"
import java.util.*;
interface I {
int m();
}
public class SampleSafeVarargs {
{
I i = () -> {
//noinspection CodeBl<caret>ock2Expr
return foo();
};
}
int foo() {
return 1;
}
}