Ooprs!!1
This commit is contained in:
parent
2943026dd5
commit
4ab667b37e
@ -87,7 +87,7 @@ class IntRange2Set private constructor(private val first: Int, private val last:
|
|||||||
}
|
}
|
||||||
|
|
||||||
override fun isEmpty(): Boolean {
|
override fun isEmpty(): Boolean {
|
||||||
return last > first
|
return last < first
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun toArray(a: IntArray?): IntArray {
|
override fun toArray(a: IntArray?): IntArray {
|
||||||
@ -158,7 +158,7 @@ class IntRange2Set private constructor(private val first: Int, private val last:
|
|||||||
}
|
}
|
||||||
|
|
||||||
override val size: Int
|
override val size: Int
|
||||||
get() = if (last > first) 0 else last - first + 1
|
get() = if (last < first) 0 else last - first + 1
|
||||||
|
|
||||||
override fun toString(): String {
|
override fun toString(): String {
|
||||||
if (isEmpty())
|
if (isEmpty())
|
||||||
|
Loading…
Reference in New Issue
Block a user