Files
openide/java/java-tests/testData/codeInsight/daemonCodeAnalyzer/quickFix/optionalToIf/afterIfPresent.java
Andrey.Cherkasov 0d10ba565e [java] Fix test data files after inspection description updating
GitOrigin-RevId: faa9f564b7a37e4c1165c24f904994b951adfccd
2021-03-18 10:49:54 +00:00

19 lines
451 B
Java

// "Fix all ''Optional' can be replaced with sequence of 'if' statements' problems in file" "true"
import java.util.*;
class Test {
void simple(String in) {
if (in != null) System.out.println(in);
}
void lambdaIsNotSimplified(String in, String p1, String p2) {
if (in == null || p1 == null) throw new IllegalArgumentException();
/* comment1 */
// comment2
String tmp = "foo";
tmp = "bar"; // comment2
}
}