mirror of
https://github.com/github/codeql.git
synced 2025-12-20 02:44:30 +01:00
34 lines
549 B
Java
34 lines
549 B
Java
public class Logic {
|
|
boolean g(int i) {
|
|
return i < 2;
|
|
}
|
|
|
|
void f(int[] a, String s) {
|
|
boolean b =
|
|
((g(1)) ?
|
|
g(2) :
|
|
true);
|
|
if (b != false) {
|
|
} else {
|
|
}
|
|
int sz = a != null ? a.length : 0;
|
|
for (int i = 0; i < sz; i++) {
|
|
int e = a[i];
|
|
if (e > 2) break;
|
|
}
|
|
if (g(3))
|
|
s = "bar";
|
|
switch (s) {
|
|
case "bar":
|
|
break;
|
|
case "foo":
|
|
break;
|
|
default:
|
|
break;
|
|
}
|
|
Object o = g(4) ? null : s;
|
|
if (o instanceof String) {
|
|
}
|
|
}
|
|
}
|