From 544fb07164e9d3327903ed67fca577ed33e9b68d Mon Sep 17 00:00:00 2001 From: Ilya Gorbunov Date: Thu, 27 Dec 2018 21:00:43 +0300 Subject: [PATCH] Fix nullability of array type argument --- .../src/main/kotlin/kotlin/collections/ArrayUtil.kt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/runtime/src/main/kotlin/kotlin/collections/ArrayUtil.kt b/runtime/src/main/kotlin/kotlin/collections/ArrayUtil.kt index a0f580b30f5..9925d28e423 100644 --- a/runtime/src/main/kotlin/kotlin/collections/ArrayUtil.kt +++ b/runtime/src/main/kotlin/kotlin/collections/ArrayUtil.kt @@ -213,7 +213,7 @@ internal fun Array.resetAt(index: Int) { @SymbolName("Kotlin_Array_fillImpl") @PointsTo(0b01000, 0, 0, 0b00001) // points to , points to . -external private fun fillImpl(array: Array, fromIndex: Int, toIndex: Int, value: Any?) +external private fun fillImpl(array: Array, fromIndex: Int, toIndex: Int, value: Any?) @SymbolName("Kotlin_IntArray_fillImpl") external private fun fillImpl(array: IntArray, fromIndex: Int, toIndex: Int, value: Int) @@ -226,7 +226,7 @@ external private fun fillImpl(array: IntArray, fromIndex: Int, toIndex: Int, val * either throwing exception or returning some kind of implementation-specific default value. */ internal fun Array.resetRange(fromIndex: Int, toIndex: Int) { - fillImpl(@Suppress("UNCHECKED_CAST") (this as Array), fromIndex, toIndex, null) + fillImpl(@Suppress("UNCHECKED_CAST") (this as Array), fromIndex, toIndex, null) } internal fun IntArray.fill(fromIndex: Int, toIndex: Int, value: Int) { @@ -235,8 +235,8 @@ internal fun IntArray.fill(fromIndex: Int, toIndex: Int, value: Int) { @SymbolName("Kotlin_Array_copyImpl") @PointsTo(0b000100, 0, 0b000001) // points to , points to . -external private fun copyImpl(array: Array, fromIndex: Int, - destination: Array, toIndex: Int, count: Int) +external private fun copyImpl(array: Array, fromIndex: Int, + destination: Array, toIndex: Int, count: Int) @SymbolName("Kotlin_ByteArray_copyImpl") external private fun copyImpl(array: ByteArray, fromIndex: Int, @@ -299,8 +299,8 @@ external private fun copyImpl(array: BooleanArray, fromIndex: Int, @PublishedApi internal fun Array.copyRangeTo( destination: Array, fromIndex: Int, toIndex: Int, destinationIndex: Int = 0) { - copyImpl(@Suppress("UNCHECKED_CAST") (this as Array), fromIndex, - @Suppress("UNCHECKED_CAST") (destination as Array), + copyImpl(@Suppress("UNCHECKED_CAST") (this as Array), fromIndex, + @Suppress("UNCHECKED_CAST") (destination as Array), destinationIndex, toIndex - fromIndex) }