Fix plain wrong unsigned rem implementation
This commit is contained in:
@@ -10,7 +10,7 @@ internal fun uintCompare(v1: Int, v2: Int): Int = (v1 xor Int.MIN_VALUE).compare
|
||||
internal fun ulongCompare(v1: Long, v2: Long): Int = (v1 xor Long.MIN_VALUE).compareTo(v2 xor Long.MIN_VALUE)
|
||||
|
||||
internal fun uintDivide(v1: UInt, v2: UInt): UInt = (v1.toLong() / v2.toLong()).toUInt()
|
||||
internal fun uintRemainder(v1: UInt, v2: UInt): UInt = (v1.toLong() / v2.toLong()).toUInt()
|
||||
internal fun uintRemainder(v1: UInt, v2: UInt): UInt = (v1.toLong() % v2.toLong()).toUInt()
|
||||
|
||||
// TODO: Add reference to Guava implementation source
|
||||
internal fun ulongDivide(v1: ULong, v2: ULong): ULong {
|
||||
|
||||
Reference in New Issue
Block a user