mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-22 11:29:28 +07:00
GitOrigin-RevId: 0d7671705a883d921d7935fc955a8b114f984c46
22 lines
594 B
Java
22 lines
594 B
Java
import java.util.*;
|
|
|
|
public class WidenMulInLoop {
|
|
void test1() {
|
|
for (int i = 0; <warning descr="Condition 'i < Integer.MAX_VALUE' is always 'true'">i < Integer.MAX_VALUE</warning>; <warning descr="Variable update does nothing">i</warning> *= 3) {
|
|
System.out.println(i);
|
|
}
|
|
}
|
|
|
|
void test2() {
|
|
for (int i = 1; <warning descr="Condition 'i < Integer.MAX_VALUE' is always 'true'">i < Integer.MAX_VALUE</warning>; i *= 2) {
|
|
System.out.println(i);
|
|
}
|
|
}
|
|
|
|
void test3() {
|
|
for (int i = 1; i < Integer.MAX_VALUE; i *= 3) {
|
|
System.out.println(i);
|
|
}
|
|
}
|
|
}
|