Suspicious oddness check
Reports odd-even checks of the following form: x % 2 == 1
. Such checks fail when used with negative odd values. Consider using x % 2 != 0
or (x & 1) == 1
instead.
Inspection Details | |
---|---|
Available in: | IntelliJ IDEA 2023.3, Qodana for JVM 2023.3 |
Plugin: | Java, 233.SNAPSHOT |
Last modified: 13 July 2023