mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
dfa: don't walk equals() method argument twice (IDEA-118971)
This commit is contained in:
@@ -21,4 +21,15 @@ class Test {
|
||||
System.out.println(<warning descr="Method invocation 'parentNode.toString()' may produce 'java.lang.NullPointerException'">parentNode.toString()</warning>);
|
||||
}
|
||||
|
||||
public static int foo(String a, String b) {
|
||||
if (a.equals(b.startsWith("a") ? b : "")) {
|
||||
return 0;
|
||||
}
|
||||
return a.length();
|
||||
}
|
||||
|
||||
static boolean isEmpty(String s) {
|
||||
return s.length() == 0;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user