MIN_VALUE step in fromClosedRange() since 1.3
Reports IntProgression.fromClosedRange()
and LongProgression.fromClosedRange()
with MIN_VALUE
step.
It is prohibited to call IntProgression.fromClosedRange()
and LongProgression.fromClosedRange()
with MIN_VALUE
step. All such calls should be checked during migration to Kotlin 1.3+.
Example:
IntProgression.fromClosedRange(12, 143, Int.MIN_VALUE)
To fix the problem change the step of the progression.
Inspection Details | |
---|---|
Available in: | IntelliJ IDEA 2023.3, Qodana for JVM 2023.3 |
Plugin: | Kotlin, @snapshot@ |
Last modified: 13 July 2023