@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun < T > Array < out T > . copyInto ( destination : Array < T > , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : Array < T >

{ <EOL> @ Suppress ( "<STR_LIT:UNCHECKED_CAST>" ) <EOL> arrayCopy ( this as Array < Any ? > , startIndex , destination as Array < Any ? > , destinationOffset , endIndex - startIndex ) <EOL> return destination <EOL> }

/**
 * Copies this array or its subrange into the [destination] array and returns that array.
 *
 * It's allowed to pass the same array in the [destination] and even specify the subrange so that it overlaps with the destination range.
 *
 * @param destination the array to copy to.
 * @param destinationOffset the position in the [destination] array to copy to, 0 by default.
 * @param startIndex the beginning (inclusive) of the subrange to copy, 0 by default.
 * @param endIndex the end (exclusive) of the subrange to copy, size of this array by default.
 *
 * @throws IndexOutOfBoundsException or [IllegalArgumentException] when [startIndex] or [endIndex] is out of range of this array indices or when `startIndex > endIndex`.
 * @throws IndexOutOfBoundsException when the subrange doesn't fit into the [destination] array starting at the specified [destinationOffset],
 * or when that index is out of the [destination] array indices range.
 *
 * @return the [destination] array.
 */


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun ByteArray . copyInto ( destination : ByteArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : ByteArray

{ <EOL> arrayCopy ( this , startIndex , destination , destinationOffset , endIndex - startIndex ) <EOL> return destination <EOL> }


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun ShortArray . copyInto ( destination : ShortArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : ShortArray


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun IntArray . copyInto ( destination : IntArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : IntArray


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun LongArray . copyInto ( destination : LongArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : LongArray


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun FloatArray . copyInto ( destination : FloatArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : FloatArray


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun DoubleArray . copyInto ( destination : DoubleArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : DoubleArray


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun BooleanArray . copyInto ( destination : BooleanArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : BooleanArray


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun CharArray . copyInto ( destination : CharArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = size ) : CharArray


public actual fun < T > Array < T > . copyOf ( ) : Array < T >

{ <EOL> return this . copyOfUninitializedElements ( size ) <EOL> }

/**
 * Returns new array which is a copy of the original array.
 *
 * @sample samples.collections.Arrays.CopyOfOperations.copyOf
 */


public actual fun ByteArray . copyOf ( ) : ByteArray


public actual fun ShortArray . copyOf ( ) : ShortArray


public actual fun IntArray . copyOf ( ) : IntArray


public actual fun LongArray . copyOf ( ) : LongArray


public actual fun FloatArray . copyOf ( ) : FloatArray


public actual fun DoubleArray . copyOf ( ) : DoubleArray


public actual fun BooleanArray . copyOf ( ) : BooleanArray


public actual fun CharArray . copyOf ( ) : CharArray


public actual fun ByteArray . copyOf ( newSize : Int ) : ByteArray

{ <EOL> return this . copyOfUninitializedElements ( newSize ) <EOL> }

/**
 * Returns new array which is a copy of the original array, resized to the given [newSize].
 * The copy is either truncated or padded at the end with zero values if necessary.
 *
 * - If [newSize] is less than the size of the original array, the copy array is truncated to the [newSize].
 * - If [newSize] is greater than the size of the original array, the extra elements in the copy array are filled with zero values.
 *
 * @sample samples.collections.Arrays.CopyOfOperations.resizedPrimitiveCopyOf
 */


public actual fun ShortArray . copyOf ( newSize : Int ) : ShortArray


public actual fun IntArray . copyOf ( newSize : Int ) : IntArray


public actual fun LongArray . copyOf ( newSize : Int ) : LongArray


public actual fun FloatArray . copyOf ( newSize : Int ) : FloatArray


public actual fun DoubleArray . copyOf ( newSize : Int ) : DoubleArray


public actual fun BooleanArray . copyOf ( newSize : Int ) : BooleanArray

/**
 * Returns new array which is a copy of the original array, resized to the given [newSize].
 * The copy is either truncated or padded at the end with `false` values if necessary.
 *
 * - If [newSize] is less than the size of the original array, the copy array is truncated to the [newSize].
 * - If [newSize] is greater than the size of the original array, the extra elements in the copy array are filled with `false` values.
 *
 * @sample samples.collections.Arrays.CopyOfOperations.resizedPrimitiveCopyOf
 */


public actual fun CharArray . copyOf ( newSize : Int ) : CharArray

/**
 * Returns new array which is a copy of the original array, resized to the given [newSize].
 * The copy is either truncated or padded at the end with null char (`\u0000`) values if necessary.
 *
 * - If [newSize] is less than the size of the original array, the copy array is truncated to the [newSize].
 * - If [newSize] is greater than the size of the original array, the extra elements in the copy array are filled with null char (`\u0000`) values.
 *
 * @sample samples.collections.Arrays.CopyOfOperations.resizedPrimitiveCopyOf
 */


public actual fun < T > Array < T > . copyOf ( newSize : Int ) : Array < T ? >

{ <EOL> return this . copyOfNulls ( newSize ) <EOL> }

/**
 * Returns new array which is a copy of the original array, resized to the given [newSize].
 * The copy is either truncated or padded at the end with `null` values if necessary.
 *
 * - If [newSize] is less than the size of the original array, the copy array is truncated to the [newSize].
 * - If [newSize] is greater than the size of the original array, the extra elements in the copy array are filled with `null` values.
 *
 * @sample samples.collections.Arrays.CopyOfOperations.resizingCopyOf
 */


public actual fun < T > Array < T > . copyOfRange ( fromIndex : Int , toIndex : Int ) : Array < T >

{ <EOL> checkCopyOfRangeArguments ( fromIndex , toIndex , size ) <EOL> return copyOfUninitializedElements ( fromIndex , toIndex ) <EOL> }

/**
 * Returns a new array which is a copy of the specified range of the original array.
 *
 * @param fromIndex the start of the range (inclusive) to copy.
 * @param toIndex the end of the range (exclusive) to copy.
 *
 * @throws IndexOutOfBoundsException if [fromIndex] is less than zero or [toIndex] is greater than the size of this array.
 * @throws IllegalArgumentException if [fromIndex] is greater than [toIndex].
 */


public actual fun ByteArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : ByteArray


public actual fun ShortArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : ShortArray


public actual fun IntArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : IntArray


public actual fun LongArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : LongArray


public actual fun FloatArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : FloatArray


public actual fun DoubleArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : DoubleArray


public actual fun BooleanArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : BooleanArray


public actual fun CharArray . copyOfRange ( fromIndex : Int , toIndex : Int ) : CharArray


internal fun < T > Array < T > . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : Array < T >

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = arrayOfUninitializedElements < T > ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }

/**
 * Returns new array which is a copy of the original array's range between [fromIndex] (inclusive)
 * and [toIndex] (exclusive) with new elements filled with **lateinit** _uninitialized_ values.
 * Attempts to read _uninitialized_ values from this array work in implementation-dependent manner,
 * either throwing exception or returning some kind of implementation-specific default value.
 */


internal fun ByteArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : ByteArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = ByteArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun ShortArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : ShortArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = ShortArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun IntArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : IntArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = IntArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun LongArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : LongArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = LongArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun FloatArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : FloatArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = FloatArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun DoubleArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : DoubleArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = DoubleArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun BooleanArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : BooleanArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = BooleanArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun CharArray . copyOfUninitializedElements ( fromIndex : Int , toIndex : Int ) : CharArray

{ <EOL> val newSize = toIndex - fromIndex <EOL> if ( newSize < <NUM_LIT:0> ) { <EOL> throw IllegalArgumentException ( "<STR_LIT>" ) <EOL> } <EOL> val result = CharArray ( newSize ) <EOL> this . copyInto ( result , <NUM_LIT:0> , fromIndex , toIndex . coerceAtMost ( size ) ) <EOL> return result <EOL> }


internal fun < T > Array < T > . copyOfUninitializedElements ( newSize : Int ) : Array < T >

{ <EOL> return copyOfUninitializedElements ( <NUM_LIT:0> , newSize ) <EOL> }

/**
 * Returns new array which is a copy of the original array with new elements filled with **lateinit** _uninitialized_ values.
 * Attempts to read _uninitialized_ values from this array work in implementation-dependent manner,
 * either throwing exception or returning some kind of implementation-specific default value.
 */


internal fun ByteArray . copyOfUninitializedElements ( newSize : Int ) : ByteArray


internal fun ShortArray . copyOfUninitializedElements ( newSize : Int ) : ShortArray


internal fun IntArray . copyOfUninitializedElements ( newSize : Int ) : IntArray


internal fun LongArray . copyOfUninitializedElements ( newSize : Int ) : LongArray


internal fun FloatArray . copyOfUninitializedElements ( newSize : Int ) : FloatArray


internal fun DoubleArray . copyOfUninitializedElements ( newSize : Int ) : DoubleArray


internal fun BooleanArray . copyOfUninitializedElements ( newSize : Int ) : BooleanArray


internal fun CharArray . copyOfUninitializedElements ( newSize : Int ) : CharArray


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun < T > Array < T > . fill ( element : T , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit

{ <EOL> arrayFill ( this , fromIndex , toIndex , element ) <EOL> }

/**
 * Fills this array or its subrange with the specified [element] value.
 *
 * @param fromIndex the start of the range (inclusive) to fill, 0 by default.
 * @param toIndex the end of the range (exclusive) to fill, size of this array by default.
 *
 * @throws IndexOutOfBoundsException if [fromIndex] is less than zero or [toIndex] is greater than the size of this array.
 * @throws IllegalArgumentException if [fromIndex] is greater than [toIndex].
 */


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun ByteArray . fill ( element : Byte , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun ShortArray . fill ( element : Short , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun IntArray . fill ( element : Int , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun LongArray . fill ( element : Long , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun FloatArray . fill ( element : Float , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun DoubleArray . fill ( element : Double , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun BooleanArray . fill ( element : Boolean , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.3>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun CharArray . fill ( element : Char , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


public actual operator fun < T > Array < T > . plus ( element : T ) : Array < T >

{ <EOL> val index = size <EOL> val result = copyOfUninitializedElements ( index + <NUM_LIT:1> ) <EOL> result [ index ] = element <EOL> return result <EOL> }

/**
 * Returns an array containing all elements of the original array and then the given [element].
 */


public actual operator fun ByteArray . plus ( element : Byte ) : ByteArray


public actual operator fun ShortArray . plus ( element : Short ) : ShortArray


public actual operator fun IntArray . plus ( element : Int ) : IntArray


public actual operator fun LongArray . plus ( element : Long ) : LongArray


public actual operator fun FloatArray . plus ( element : Float ) : FloatArray


public actual operator fun DoubleArray . plus ( element : Double ) : DoubleArray


public actual operator fun BooleanArray . plus ( element : Boolean ) : BooleanArray


public actual operator fun CharArray . plus ( element : Char ) : CharArray


public actual operator fun < T > Array < T > . plus ( elements : Collection < T > ) : Array < T >

{ <EOL> var index = size <EOL> val result = copyOfUninitializedElements ( index + elements . size ) <EOL> for ( element in elements ) result [ index ++ ] = element <EOL> return result <EOL> }

/**
 * Returns an array containing all elements of the original array and then all elements of the given [elements] collection.
 */


public actual operator fun ByteArray . plus ( elements : Collection < Byte > ) : ByteArray


public actual operator fun ShortArray . plus ( elements : Collection < Short > ) : ShortArray


public actual operator fun IntArray . plus ( elements : Collection < Int > ) : IntArray


public actual operator fun LongArray . plus ( elements : Collection < Long > ) : LongArray


public actual operator fun FloatArray . plus ( elements : Collection < Float > ) : FloatArray


public actual operator fun DoubleArray . plus ( elements : Collection < Double > ) : DoubleArray


public actual operator fun BooleanArray . plus ( elements : Collection < Boolean > ) : BooleanArray


public actual operator fun CharArray . plus ( elements : Collection < Char > ) : CharArray


public actual operator fun < T > Array < T > . plus ( elements : Array < out T > ) : Array < T >

{ <EOL> val thisSize = size <EOL> val arraySize = elements . size <EOL> val result = copyOfUninitializedElements ( thisSize + arraySize ) <EOL> elements . copyInto ( result , thisSize ) <EOL> return result <EOL> }

/**
 * Returns an array containing all elements of the original array and then all elements of the given [elements] array.
 */


public actual operator fun ByteArray . plus ( elements : ByteArray ) : ByteArray


public actual operator fun ShortArray . plus ( elements : ShortArray ) : ShortArray


public actual operator fun IntArray . plus ( elements : IntArray ) : IntArray


public actual operator fun LongArray . plus ( elements : LongArray ) : LongArray


public actual operator fun FloatArray . plus ( elements : FloatArray ) : FloatArray


public actual operator fun DoubleArray . plus ( elements : DoubleArray ) : DoubleArray


public actual operator fun BooleanArray . plus ( elements : BooleanArray ) : BooleanArray


public actual operator fun CharArray . plus ( elements : CharArray ) : CharArray


@ kotlin . internal . InlineOnly <EOL> public actual inline fun < T > Array < T > . plusElement ( element : T ) : Array < T >

{ <EOL> return plus ( element ) <EOL> }


public actual fun IntArray . sort ( ) : Unit

{ <EOL> if ( size > <NUM_LIT:1> ) sortArray ( this , <NUM_LIT:0> , size ) <EOL> }

/**
 * Sorts the array in-place.
 *
 * @sample samples.collections.Arrays.Sorting.sortArray
 */


public actual fun LongArray . sort ( ) : Unit


public actual fun ByteArray . sort ( ) : Unit


public actual fun ShortArray . sort ( ) : Unit


public actual fun DoubleArray . sort ( ) : Unit


public actual fun FloatArray . sort ( ) : Unit


public actual fun CharArray . sort ( ) : Unit


public actual fun < T : Comparable < T > > Array < out T > . sort ( ) : Unit

/**
 * Sorts the array in-place according to the natural order of its elements.
 *
 * The sort is _stable_. It means that equal elements preserve their order relative to each other after sorting.
 *
 * @sample samples.collections.Arrays.Sorting.sortArrayOfComparable
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun < T : Comparable < T > > Array < out T > . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit

{ <EOL> AbstractList . checkRangeIndexes ( fromIndex , toIndex , size ) <EOL> sortArray ( this , fromIndex , toIndex ) <EOL> }

/**
 * Sorts a range in the array in-place.
 *
 * The sort is _stable_. It means that equal elements preserve their order relative to each other after sorting.
 *
 * @param fromIndex the start of the range (inclusive) to sort, 0 by default.
 * @param toIndex the end of the range (exclusive) to sort, size of this array by default.
 *
 * @throws IndexOutOfBoundsException if [fromIndex] is less than zero or [toIndex] is greater than the size of this array.
 * @throws IllegalArgumentException if [fromIndex] is greater than [toIndex].
 *
 * @sample samples.collections.Arrays.Sorting.sortRangeOfArrayOfComparable
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun ByteArray . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit

/**
 * Sorts a range in the array in-place.
 *
 * @param fromIndex the start of the range (inclusive) to sort, 0 by default.
 * @param toIndex the end of the range (exclusive) to sort, size of this array by default.
 *
 * @throws IndexOutOfBoundsException if [fromIndex] is less than zero or [toIndex] is greater than the size of this array.
 * @throws IllegalArgumentException if [fromIndex] is greater than [toIndex].
 *
 * @sample samples.collections.Arrays.Sorting.sortRangeOfArray
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun ShortArray . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun IntArray . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun LongArray . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun FloatArray . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun DoubleArray . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun CharArray . sort ( fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit


public actual fun < T > Array < out T > . sortWith ( comparator : Comparator < in T > ) : Unit

{ <EOL> if ( size > <NUM_LIT:1> ) sortArrayWith ( this , <NUM_LIT:0> , size , comparator ) <EOL> }

/**
 * Sorts the array in-place according to the order specified by the given [comparator].
 *
 * The sort is _stable_. It means that equal elements preserve their order relative to each other after sorting.
 */


@ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun < T > Array < out T > . sortWith ( comparator : Comparator < in T > , fromIndex : Int = <NUM_LIT:0> , toIndex : Int = size ) : Unit

{ <EOL> AbstractList . checkRangeIndexes ( fromIndex , toIndex , size ) <EOL> sortArrayWith ( this , fromIndex , toIndex , comparator ) <EOL> }

/**
 * Sorts a range in the array in-place with the given [comparator].
 *
 * The sort is _stable_. It means that equal elements preserve their order relative to each other after sorting.
 *
 * @param fromIndex the start of the range (inclusive) to sort, 0 by default.
 * @param toIndex the end of the range (exclusive) to sort, size of this array by default.
 *
 * @throws IndexOutOfBoundsException if [fromIndex] is less than zero or [toIndex] is greater than the size of this array.
 * @throws IllegalArgumentException if [fromIndex] is greater than [toIndex].
 */


public actual fun ByteArray . toTypedArray ( ) : Array < Byte >

{ <EOL> return Array ( size ) { index -> this [ index ] } <EOL> }

/**
 * Returns a *typed* object array containing all of the elements of this primitive array.
 */


public actual fun ShortArray . toTypedArray ( ) : Array < Short >


public actual fun IntArray . toTypedArray ( ) : Array < Int >


public actual fun LongArray . toTypedArray ( ) : Array < Long >


public actual fun FloatArray . toTypedArray ( ) : Array < Float >


public actual fun DoubleArray . toTypedArray ( ) : Array < Double >


public actual fun BooleanArray . toTypedArray ( ) : Array < Boolean >


public actual fun CharArray . toTypedArray ( ) : Array < Char >


fun remember ( from : KotlinSourceSet , to : KotlinSourceSet )

{ <EOL> if ( dontRemember ) return <EOL> rememberedEdges . add ( from to to ) <EOL> }

/** Should be called from [KotlinSourceSet.dependsOn] method,
 * so depends on edges are tracked and can be distinguished when they added via [addDependsOnEdgeFromTemplate] */


private fun tryExpandExpectNestedClassActualizedViaTypealias ( expectNestedClassType : ConeClassLikeType , expectNestedClassSymbol : FirRegularClassSymbol , ) : ConeClassLikeType ?

{ <EOL> val expectNestedClassId = expectNestedClassSymbol . classId <EOL> val expectOutermostClassId = expectNestedClassId . outermostClassId <EOL> val actualTypealiasSymbol = expectOutermostClassId . toSymbol ( actualSession ) as? FirTypeAliasSymbol ? : return null <EOL> val actualOutermostClassId = actualTypealiasSymbol . fullyExpandedClass ( actualSession ) ? . classId ? : return null <EOL> val actualNestedClassId = ClassId . fromString ( expectNestedClassId . asString ( ) . replaceFirst ( expectOutermostClassId . asString ( ) , actualOutermostClassId . asString ( ) ) ) <EOL> return actualNestedClassId . constructClassLikeType ( expectNestedClassType . typeArguments , expectNestedClassType . isNullable , expectNestedClassType . attributes ) <EOL> }

/**
 * In case of `expect` nested classes actualized via typealias we can't simply find actual symbol by `expect` `ClassId`
 * (like we do for top-level classes), because `ClassId` is different.
 * For example, `expect` class `com/example/ExpectClass.Nested` may have actual with id `real/package/ActualTypeliasTarget.Nested`.
 * So, we first expand outermost class, and then construct `ClassId` for nested class.
 */


fun foo ( p : Int , p2 : Double ) : Short

= <NUM_LIT:1>

/**
 * Function foo description
 *
 * @param p first Integer to consume
 * @param p2 second Double to consume
 * @return Short, constant 1
 */


{ <EOL> val testProject = mixedJvmTestProject { <EOL> dokkaConfiguration { <EOL> moduleName = "<STR_LIT>" <EOL> jvmSourceSet { <EOL> } <EOL> } <EOL> kotlinSourceDirectory { <EOL> ktFile ( pathFromSrc = "<STR_LIT>" ) { <EOL> + "<STR_LIT>" <EOL> } <EOL> javaFile ( pathFromSrc = "<STR_LIT>" ) { <EOL> + """<STR_LIT>""" <EOL> } <EOL> } <EOL> javaSourceDirectory { <EOL> ktFile ( pathFromSrc = "<STR_LIT>" ) { <EOL> + "<STR_LIT>" <EOL> } <EOL> javaFile ( pathFromSrc = "<STR_LIT>" ) { <EOL> + """<STR_LIT>""" <EOL> } <EOL> } <EOL> } <EOL> val module = testProject . parse ( ) <EOL> assertEquals ( "<STR_LIT>" , module . name ) <EOL> assertEquals ( <NUM_LIT:1> , module . packages . size ) <EOL> val pckg = module . packages [ <NUM_LIT:0> ] <EOL> assertEquals ( "<STR_LIT:test>" , pckg . name ) <EOL> assertEquals ( <NUM_LIT:2> , pckg . classlikes . size ) <EOL> assertEquals ( <NUM_LIT:2> , pckg . functions . size ) <EOL> val firstClasslike = pckg . classlikes [ <NUM_LIT:0> ] <EOL> assertEquals ( "<STR_LIT>" , firstClasslike . name ) <EOL> val secondClasslike = pckg . classlikes [ <NUM_LIT:1> ] <EOL> assertEquals ( "<STR_LIT>" , secondClasslike . name ) <EOL> val functions = pckg . functions . sortedBy { it . name } <EOL> val firstFunction = functions [ <NUM_LIT:0> ] <EOL> assertEquals ( "<STR_LIT:bar>" , firstFunction . name ) <EOL> val secondFunction = functions [ <NUM_LIT:1> ] <EOL> assertEquals ( "<STR_LIT:foo>" , secondFunction . name ) <EOL> }

/**
 * Used as a sample for [mixedJvmTestProject]
 */


fun < T > DataStreamWriter < T > . forEachBatch ( func : ( batch : Dataset < T > , batchId : Long ) -> Unit , ) : DataStreamWriter < T >

= foreachBatch ( VoidFunction2 ( func ) )

/**
 * :: Experimental ::
 *
 * (Scala-specific) Sets the output of the streaming query to be processed using the provided
 * function. This is supported only in the micro-batch execution modes (that is, when the
 * trigger is not continuous). In every micro-batch, the provided function will be called in
 * every micro-batch with (i) the output rows as a Dataset and (ii) the batch identifier.
 * The batchId can be used to deduplicate and transactionally write the output
 * (that is, the provided Dataset) to external systems. The output Dataset is guaranteed
 * to be exactly the same for the same batchId (assuming all operations are deterministic
 * in the query).
 *
 * @since 2.4.0
 */


public suspend fun < T > runInterruptible ( context : CoroutineContext = EmptyCoroutineContext , block : ( ) -> T ) : T

= withContext ( context ) { <EOL> runInterruptibleInExpectedContext ( coroutineContext , block ) <EOL> }

/**
 * Calls the specified [block] with a given coroutine context in
 * [an interruptible manner](https://docs.oracle.com/javase/tutorial/essential/concurrency/interrupt.html).
 * The blocking code block will be interrupted and this function will throw [CancellationException]
 * if the coroutine is cancelled.
 *
 * Example:
 *
 * ```
 * withTimeout(500L) { // Cancels coroutine on timeout
 * runInterruptible { // Throws CancellationException if interrupted
 * doSomethingBlocking() // Interrupted on coroutines cancellation
 * }
 * }
 * ```
 *
 * There is an optional [context] parameter to this function working just like [withContext].
 * It enables single-call conversion of interruptible Java methods into suspending functions.
 * With one call here we are moving the call to [Dispatchers.IO] and supporting interruption:
 *
 * ```
 * suspend fun <T> BlockingQueue<T>.awaitTake(): T =
 * runInterruptible(Dispatchers.IO) { queue.take() }
 * ```
 *
 * `runInterruptible` uses [withContext] as an underlying mechanism for switching context,
 * meaning that the supplied [block] is invoked in an [undispatched][CoroutineStart.UNDISPATCHED]
 * manner directly by the caller if [CoroutineDispatcher] from the current [coroutineContext][currentCoroutineContext]
 * is the same as the one supplied in [context].
 */


public fun < T > xBegin ( column : ColumnReference < T > ) : PositionalMapping < T >

{ <EOL> return addPositionalMapping < T > ( X_BEGIN , column . name ( ) , null ) <EOL> }

/**
 * Maps the `xBegin` aesthetic to a data column by [ColumnReference].
 *
 * @param column the data column to be mapped.
 * @return a [PositionalMapping] object representing the mapping.
 */


public fun < T > xBegin ( column : KProperty < T > ) : PositionalMapping < T >

{ <EOL> return addPositionalMapping < T > ( X_BEGIN , column . name , null ) <EOL> }

/**
 * Maps the `xBegin` aesthetic to a data column by [KProperty].
 *
 * @param column the data column to be mapped.
 * @return a [PositionalMapping] object representing the mapping.
 */


public fun xBegin ( column : String ) : PositionalMapping < Any ? >

{ <EOL> return addPositionalMapping ( X_BEGIN , column , null ) <EOL> }

/**
 * Maps the `xBegin` aesthetic to a data column by [String].
 *
 * @param column the data column to be mapped.
 * @return a [PositionalMapping] object representing the mapping.
 */


public fun < T > xBegin ( values : Iterable < T > ) : PositionalMapping < T >

{ <EOL> return addPositionalMapping < T > ( X_BEGIN , values . toList ( ) , null , null ) <EOL> }

/**
 * Maps the `xBegin` aesthetic to iterable of values.
 *
 * @param values the iterable of values to be mapped.
 * @return a [PositionalMapping] object representing the mapping.
 */


public fun < T > xBegin ( values : DataColumn < T > ) : PositionalMapping < T >

{ <EOL> return addPositionalMapping < T > ( X_BEGIN , values , null ) <EOL> }

/**
 * Maps the `xBegin` aesthetic to a data column.
 *
 * @param values the data column to be mapped.
 * @return a [PositionalMapping] object representing the mapping.
 */


public fun getLabel ( dataSource : D ) : Float

/**
 * Returns a label for provided [dataSource].
 */


fun List < FirAnnotation > . computeTypeAttributes ( session : FirSession , predefined : List < ConeAttribute < * > > = emptyList ( ) , allowExtensionFunctionType : Boolean = true , shouldExpandTypeAliases : Boolean ) : ConeAttributes

{ <EOL> if ( this . isEmpty ( ) ) { <EOL> if ( predefined . isEmpty ( ) ) return ConeAttributes . Empty <EOL> return ConeAttributes . create ( predefined ) <EOL> } <EOL> val attributes = mutableListOf < ConeAttribute < * > > ( ) <EOL> attributes += predefined <EOL> val customAnnotations = mutableListOf < FirAnnotation > ( ) <EOL> for ( annotation in this ) { <EOL> val classId = when ( shouldExpandTypeAliases ) { <EOL> true -> annotation . tryExpandClassId ( session ) <EOL> false -> annotation . resolvedType . classId <EOL> } <EOL> when ( classId ) { <EOL> CompilerConeAttributes . Exact . ANNOTATION_CLASS_ID -> attributes += CompilerConeAttributes . Exact <EOL> CompilerConeAttributes . NoInfer . ANNOTATION_CLASS_ID -> attributes += CompilerConeAttributes . NoInfer <EOL> CompilerConeAttributes . ExtensionFunctionType . ANNOTATION_CLASS_ID -> when { <EOL> allowExtensionFunctionType -> attributes += CompilerConeAttributes . ExtensionFunctionType <EOL> } <EOL> CompilerConeAttributes . ContextFunctionTypeParams . ANNOTATION_CLASS_ID -> <EOL> attributes += <EOL> CompilerConeAttributes . ContextFunctionTypeParams ( annotation . extractContextReceiversCount ( ) ? : <NUM_LIT:0> ) <EOL> CompilerConeAttributes . UnsafeVariance . ANNOTATION_CLASS_ID -> attributes += CompilerConeAttributes . UnsafeVariance <EOL> else -> { <EOL> val attributeFromPlugin = session . extensionService . typeAttributeExtensions . firstNotNullOfOrNull { <EOL> it . extractAttributeFromAnnotation ( annotation ) <EOL> } <EOL> if ( attributeFromPlugin != null ) { <EOL> attributes += attributeFromPlugin <EOL> } else { <EOL> customAnnotations += annotation <EOL> } <EOL> } <EOL> } <EOL> } <EOL> if ( customAnnotations . isNotEmpty ( ) ) { <EOL> attributes += CustomAnnotationTypeAttribute ( customAnnotations ) <EOL> } <EOL> return ConeAttributes . create ( attributes ) <EOL> }

/**
 * [shouldExpandTypeAliases] should be set to `false` if this function is called during deserialization of some binary declaration
 * For details see KT-57876
 */


@ ExperimentalKotlinGradlePluginApi <EOL> fun compilerOptions ( configure : CO . ( ) -> Unit )

{ <EOL> configure ( compilerOptions ) <EOL> }

/**
 * Configures the [compilerOptions] with the provided configuration.
 */


@ ExperimentalKotlinGradlePluginApi <EOL> fun compilerOptions ( configure : Action < CO > )

{ <EOL> configure . execute ( compilerOptions ) <EOL> }


@ TestOnly <EOL> public abstract fun publishGlobalModuleStateModification ( )

/**
 * Publishes an event of global modification of the module state of all [KtModule]s.
 */


@ TestOnly <EOL> public abstract fun publishGlobalSourceModuleStateModification ( )

/**
 * Publishes an event of global modification of the module state of all source [KtModule]s.
 */


@ TestOnly <EOL> public abstract fun publishGlobalSourceOutOfBlockModification ( )

/**
 * Publishes an event of global out-of-block modification of all source [KtModule]s. The event does not invalidate module state like
 * [publishGlobalSourceModuleStateModification], so some module structure-specific caches might persist.
 */


public fun isOpenApiStr ( text : String ) : Boolean

= try { <EOL> val parsed = OpenAPIParser ( ) . readContents ( text , null , null ) <EOL> parsed . openAPI ? . components ? . schemas != null <EOL> } catch ( e : Throwable ) { <EOL> logger . debug ( e ) { "<STR_LIT>" } <EOL> false <EOL> }

/** Needs to have any type schemas to convert. */


public abstract fun getKtFiles ( ) : List < KtResolveExtensionFile >

/**
 * Get the list of files that should be generated for the module. Returned files should contain valid Kotlin code.
 *
 * If the content of these files becomes invalid (e.g., because the source declarations they were based on changed), the
 * [KtResolveExtension] must publish an out-of-block modification event via the Analysis API message bus:
 * [org.jetbrains.kotlin.analysis.providers.topics.KotlinTopics.MODULE_OUT_OF_BLOCK_MODIFICATION].
 *
 * To react to changes in Kotlin sources, [KtResolveExtension] may subscribe to Analysis API topics:
 * [org.jetbrains.kotlin.analysis.providers.topics.KotlinTopics]. If the [KtResolveExtension] both subscribes to and
 * publishes modification events, care needs to be taken that no cycles are introduced. In general, the [KtResolveExtension] should
 * never publish an event for a module A in a listener for the same module A.
 *
 * An out-of-block modification event for the [KtResolveExtension]'s associated module does not need to be published in response to an
 * out-of-block modification event for the same module, because the original event suffices for invalidation.
 *
 * @see KtResolveExtensionFile
 * @see KtResolveExtension
 */


public abstract fun getContainedPackages ( ) : Set < FqName >

/**
 * Returns the set of packages that are contained in the files provided by [getKtFiles].
 *
 * The returned package set should be a strict set of all file packages,
 * so `for-all pckg: pckg in getContainedPackages() <=> exists file: file in getKtFiles() && file.getFilePackageName() == pckg`
 *
 * @see KtResolveExtension
 */


public open fun getShadowedScope ( ) : GlobalSearchScope

= GlobalSearchScope . EMPTY_SCOPE

/**
 * Returns the scope of files that should be shadowed by the files provided by [getKtFiles].
 *
 * Any files in the module that are included in this scope will be removed from analysis results. This allows the files provided by
 * [getKtFiles] to cleanly replace those files from the module.
 *
 * If this resolve extension is being used to generate declarations that would normally be provided by sources generated by an external
 * build task, such as a resource compiler or annotation processor, the resolve extension should provide a scope here that covers those
 * externally generated sources. This will prevent collisions between the definitions provided by [getKtFiles] and those provided by the
 * (potentially stale) externally generated sources.
 */


@ kotlin . internal . InlineOnly <EOL> public inline fun < T > Lock . withLock ( action : ( ) -> T ) : T

{ <EOL> contract { callsInPlace ( action , InvocationKind . EXACTLY_ONCE ) } <EOL> lock ( ) <EOL> try { <EOL> return action ( ) <EOL> } finally { <EOL> unlock ( ) <EOL> } <EOL> }

/**
 * Executes the given [action] under this lock.
 * @return the return value of the action.
 */


@ kotlin . internal . InlineOnly <EOL> public inline fun < T > ReentrantReadWriteLock . read ( action : ( ) -> T ) : T

{ <EOL> contract { callsInPlace ( action , InvocationKind . EXACTLY_ONCE ) } <EOL> val rl = readLock ( ) <EOL> rl . lock ( ) <EOL> try { <EOL> return action ( ) <EOL> } finally { <EOL> rl . unlock ( ) <EOL> } <EOL> }

/**
 * Executes the given [action] under the read lock of this lock.
 * @return the return value of the action.
 */


@ kotlin . internal . InlineOnly <EOL> public inline fun < T > ReentrantReadWriteLock . write ( action : ( ) -> T ) : T

{ <EOL> contract { callsInPlace ( action , InvocationKind . EXACTLY_ONCE ) } <EOL> val rl = readLock ( ) <EOL> val readCount = if ( writeHoldCount == <NUM_LIT:0> ) readHoldCount else <NUM_LIT:0> <EOL> repeat ( readCount ) { rl . unlock ( ) } <EOL> val wl = writeLock ( ) <EOL> wl . lock ( ) <EOL> try { <EOL> return action ( ) <EOL> } finally { <EOL> repeat ( readCount ) { rl . lock ( ) } <EOL> wl . unlock ( ) <EOL> } <EOL> }

/**
 * Executes the given [action] under the write lock of this lock.
 *
 * The function does upgrade from read to write lock if needed, but this upgrade is not atomic
 * as such upgrade is not supported by [ReentrantReadWriteLock].
 * In order to do such upgrade this function first releases all read locks held by this thread,
 * then acquires write lock, and after releasing it acquires read locks back again.
 *
 * Therefore if the [action] inside write lock has been initiated by checking some condition,
 * the condition must be rechecked inside the [action] to avoid possible races.
 *
 * @return the return value of the action.
 */


public abstract fun hasAnnotation ( classId : ClassId , useSiteTargetFilter : AnnotationUseSiteTargetFilter = AnyAnnotationUseSiteTargetFilter , ) : Boolean

/**
 * Checks if entity contains annotation with specified [classId] and filtered by [useSiteTargetFilter].
 *
 * The semantic is equivalent to
 * ```
 * annotationsList.hasAnnotation(classId, useSiteTargetFilter) == annotationsList.annotations.any {
 * it.classId == classId && useSiteTargetFilter.isAllowed(it.useSiteTarget)
 * }
 * ```
 * @param classId [ClassId] to search
 * @param useSiteTargetFilter specific [AnnotationUseSiteTargetFilter]
 */


public abstract fun annotationsByClassId ( classId : ClassId , useSiteTargetFilter : AnnotationUseSiteTargetFilter = AnyAnnotationUseSiteTargetFilter , ) : List < KtAnnotationApplicationWithArgumentsInfo >

/**
 * A list of annotations applied with specified [classId] and filtered by [useSiteTargetFilter].
 *
 * To check if annotation is present, please use [hasAnnotation].
 *
 * The semantic is equivalent to
 * ```
 * annotationsList.annotationsByClassId(classId) == annotationsList.annotations.filter {
 * it.classId == classId && useSiteTargetFilter.isAllowed(it.useSiteTarget)
 * }
 * ```
 *
 * @see KtAnnotationApplicationWithArgumentsInfo
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:FunctionName>" , "<STR_LIT>" ) <EOL> public expect fun CancellationException ( message : String ? , cause : Throwable ? ) : CancellationException

/**
 * Creates an instance of [CancellationException] with the given [message] and [cause].
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:FunctionName>" , "<STR_LIT>" ) <EOL> public expect fun CancellationException ( cause : Throwable ? ) : CancellationException

/**
 * Creates an instance of [CancellationException] with the given [cause].
 */


public fun map ( mapping : ( Float , Float ) -> Pair < Float , Float > ) : T

/**
 * Creates a new geometric shape of the same type by applying the provided [mapping]
 * to the coordinates of the current shape.
 */


public fun KtDeclarationSymbol . render ( renderer : KtDeclarationRenderer = KtDeclarationRendererForSource . WITH_QUALIFIED_NAMES ) : String

= <EOL> withValidityAssertion { analysisSession . symbolDeclarationRendererProvider . renderDeclaration ( this , renderer ) }

/**
 * Render symbol into the representable Kotlin string
 */


public fun KtType . render ( renderer : KtTypeRenderer = KtTypeRendererForSource . WITH_QUALIFIED_NAMES , position : Variance , ) : String

= <EOL> withValidityAssertion { analysisSession . symbolDeclarationRendererProvider . renderType ( this , renderer , position ) }

/**
 * Render kotlin type into the representable Kotlin type string
 */


public fun < C > String . colsOf ( type : KType , filter : ColumnFilter < C > = { true } , ) : ColumnSet < * >

= columnGroup ( this ) . colsOf ( type , filter )

/**
 * @include [CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { "myColumnGroup".`[colsOf][String.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) }`
 *
 * `df.`[select][DataFrame.select]` { "myColumnGroup".`[colsOf][String.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) { it: `[DataColumn][DataColumn]`<`[Int][Int]`> -> it.`[size][DataColumn.size]` > 10 } }`
 *
 * @include [CommonColsOfDocs.FilterParam]
 * @include [CommonColsOfDocs.Return]
 */


public fun < C > KProperty < * > . colsOf ( type : KType , filter : ColumnFilter < C > = { true } , ) : ColumnSet < * >

/**
 * @include [CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { DataSchemaType::myColumnGroup.`[colsOf][KProperty.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) }`
 *
 * `df.`[select][DataFrame.select]` { Type::myColumnGroup.`[colsOf][KProperty.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) { it: `[DataColumn][DataColumn]`<`[Int][Int]`> -> it.`[size][DataColumn.size]` > 10 } }`
 *
 * @include [CommonColsOfDocs.FilterParam]
 * @include [CommonColsOfDocs.Return]
 */


public fun < C > ColumnPath . colsOf ( type : KType , filter : ColumnFilter < C > = { true } , ) : ColumnSet < * >

/**
 * @include [CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { "pathTo"["myColumnGroup"].`[colsOf][ColumnPath.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) }`
 *
 * `df.`[select][DataFrame.select]` { "pathTo"["myColumnGroup"].`[colsOf][ColumnPath.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) { it: `[DataColumn][DataColumn]`<`[Int][Int]`> -> it.`[size][DataColumn.size]` > 10 } }`
 *
 * @include [CommonColsOfDocs.FilterParam]
 * @include [CommonColsOfDocs.Return]
 */


public fun < C > ColumnSet < * > . colsOf ( type : KType , filter : ColumnFilter < C > = { true } , ) : TransformableColumnSet < C >

= colsOfInternal ( type , filter )

/**
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { `[cols][ColumnsSelectionDsl.cols]` { .. }.`[colsOf][ColumnSet.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) }`
 *
 * `df.`[select][DataFrame.select]` { `[cols][ColumnsSelectionDsl.cols]` { .. }.`[colsOf][ColumnSet.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) { it: `[DataColumn][DataColumn]`<`[Int][Int]`> -> it.`[size][DataColumn.size]` > 10 } }`
 *
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.FilterParam]
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.Return]
 */


public inline fun < reified C > ColumnSet < * > . colsOf ( noinline filter : ColumnFilter < C > = { true } , ) : TransformableColumnSet < C >

= colsOf ( typeOf < C > ( ) , filter )

/**
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { `[cols][ColumnsSelectionDsl.cols]` { .. }.`[colsOf][ColumnSet.colsOf]`<`[Int][Int]`>() }`
 *
 * `df.`[select][DataFrame.select]` { `[cols][ColumnsSelectionDsl.cols]` { .. }.`[colsOf][ColumnSet.colsOf]`<`[Int][Int]`> { it.`[size][DataColumn.size]` > 10 } }`
 *
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.FilterParam]
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.Return]
 */


public fun < C > ColumnsSelectionDsl < * > . colsOf ( type : KType , filter : ColumnFilter < C > = { true } , ) : TransformableColumnSet < C >

= asSingleColumn ( ) . colsOf ( type , filter )

/**
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { `[colsOf][SingleColumn.colsOf]`(`[typeOf][typeOf]`<`[Int][Int]`>()) }`
 *
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.FilterParam]
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.Return]
 */


public inline fun < reified C > ColumnsSelectionDsl < * > . colsOf ( noinline filter : ColumnFilter < C > = { true } , ) : TransformableColumnSet < C >

= asSingleColumn ( ) . colsOf ( typeOf < C > ( ) , filter )

/**
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { `[colsOf][SingleColumn.colsOf]`<`[Int][Int]`>() }`
 *
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.FilterParam]
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.Return]
 */


public fun < C > SingleColumn < DataRow < * > > . colsOf ( type : KType , filter : ColumnFilter < C > = { true } , ) : TransformableColumnSet < C >

= ensureIsColumnGroup ( ) . colsOfInternal ( type , filter )

/**
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { myColumnGroup.`[colsOf][SingleColumn.colsOf]`<`[Int][Int]`>(`[typeOf][typeOf]`<`[Int][Int]`>()) { it: `[DataColumn][DataColumn]`<`[Int][Int]`> -> it.`[size][DataColumn.size]` > 10 } }`
 *
 * `df.`[select][DataFrame.select]` { myColumnGroup.`[colsOf][SingleColumn.colsOf]`<`[Int][Int]`>(`[typeOf][typeOf]`<`[Int][Int]`>()) }`
 *
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.FilterParam]
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.Return]
 */


public inline fun < reified C > SingleColumn < DataRow < * > > . colsOf ( noinline filter : ColumnFilter < C > = { true } , ) : TransformableColumnSet < C >

= colsOf ( typeOf < C > ( ) , filter )

/**
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs]
 *
 * `df.`[select][DataFrame.select]` { myColumnGroup.`[colsOf][SingleColumn.colsOf]`<`[Int][Int]`> { it.`[size][DataColumn.size]` > 10 } }`
 *
 * `df.`[select][DataFrame.select]` { myColumnGroup.`[colsOf][SingleColumn.colsOf]`<`[Int][Int]`>() }`
 *
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.FilterParam]
 * @include [ColsOfColumnsSelectionDsl.CommonColsOfDocs.Return]
 */


@ Suppress ( "<STR_LIT:UNCHECKED_CAST>" ) <EOL> internal fun < C > ColumnsResolver < * > . colsOfInternal ( type : KType , filter : ColumnFilter < C > , ) : TransformableColumnSet < C >

= <EOL> colsInternal { <EOL> it . isSubtypeOf ( type ) && filter ( it . cast ( ) ) <EOL> } as TransformableColumnSet < C >

/**
 * If this [ColumnsResolver] is a [SingleColumn], it
 * returns a new [ColumnSet] containing the columns inside of this [SingleColumn] that
 * match the given [filter] and are the given [type].
 *
 * Else, it returns a new [ColumnSet] containing all columns in this [ColumnsResolver] that
 * match the given [filter] and are the given [type].
 */


public fun run ( )


@ Suppress ( "<STR_LIT:FunctionName>" ) <EOL> public expect inline fun Runnable ( crossinline block : ( ) -> Unit ) : Runnable

/**
 * Creates [Runnable] task instance.
 */


internal fun interpretUnaryFunction ( name : String , type : String , a : Any ? ) : Any ?

{ <EOL> when ( name ) { <EOL> "<STR_LIT:hashCode>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Boolean ) . hashCode ( ) <EOL> "<STR_LIT>" -> return ( a as Char ) . hashCode ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . hashCode ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . hashCode ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . hashCode ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . hashCode ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . hashCode ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . hashCode ( ) <EOL> "<STR_LIT:kotlin.String>" -> return ( a as String ) . hashCode ( ) <EOL> "<STR_LIT:kotlin.Any>" -> return ( a as Any ) . hashCode ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Boolean ) . not ( ) <EOL> } <EOL> "<STR_LIT:toString>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Boolean ) . toString ( ) <EOL> "<STR_LIT>" -> return ( a as Char ) . toString ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toString ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toString ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toString ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toString ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toString ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toString ( ) <EOL> "<STR_LIT:kotlin.String>" -> return ( a as String ) . toString ( ) <EOL> "<STR_LIT:kotlin.Any>" -> return ( a as Any ) . toString ( ) <EOL> "<STR_LIT:kotlin.Any?>" -> return a ? . toString ( ) ? : "<STR_LIT:null>" <EOL> "<STR_LIT>" -> return Unit . toString ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . dec ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . dec ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . dec ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . dec ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . dec ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . dec ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . dec ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . inc ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . inc ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . inc ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . inc ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . inc ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . inc ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . inc ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . toByte ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toByte ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toByte ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toByte ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toByte ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toByte ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toByte ( ) <EOL> "<STR_LIT>" -> return ( a as Number ) . toByte ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . toChar ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toChar ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toChar ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toChar ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toChar ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toChar ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toChar ( ) <EOL> "<STR_LIT>" -> return ( a as Number ) . toChar ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . toDouble ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toDouble ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toDouble ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toDouble ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toDouble ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toDouble ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toDouble ( ) <EOL> "<STR_LIT>" -> return ( a as Number ) . toDouble ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . toFloat ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toFloat ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toFloat ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toFloat ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toFloat ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toFloat ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toFloat ( ) <EOL> "<STR_LIT>" -> return ( a as Number ) . toFloat ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . toInt ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toInt ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toInt ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toInt ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toInt ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toInt ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toInt ( ) <EOL> "<STR_LIT>" -> return ( a as Number ) . toInt ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . toLong ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toLong ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toLong ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toLong ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toLong ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toLong ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toLong ( ) <EOL> "<STR_LIT>" -> return ( a as Number ) . toLong ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . toShort ( ) <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . toShort ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . toShort ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . toShort ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . toShort ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . toShort ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . toShort ( ) <EOL> "<STR_LIT>" -> return ( a as Number ) . toShort ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . unaryMinus ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . unaryMinus ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . unaryMinus ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . unaryMinus ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . unaryMinus ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . unaryMinus ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT:kotlin.Byte>" -> return ( a as Byte ) . unaryPlus ( ) <EOL> "<STR_LIT:kotlin.Short>" -> return ( a as Short ) . unaryPlus ( ) <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . unaryPlus ( ) <EOL> "<STR_LIT>" -> return ( a as Float ) . unaryPlus ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . unaryPlus ( ) <EOL> "<STR_LIT>" -> return ( a as Double ) . unaryPlus ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT:kotlin.Int>" -> return ( a as Int ) . inv ( ) <EOL> "<STR_LIT:kotlin.Long>" -> return ( a as Long ) . inv ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT:kotlin.String>" -> return ( a as String ) . length <EOL> "<STR_LIT>" -> return ( a as CharSequence ) . length <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Throwable ) . cause <EOL> } <EOL> "<STR_LIT:message>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Throwable ) . message <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as BooleanArray ) . size <EOL> "<STR_LIT>" -> return ( a as CharArray ) . size <EOL> "<STR_LIT>" -> return ( a as ByteArray ) . size <EOL> "<STR_LIT>" -> return ( a as ShortArray ) . size <EOL> "<STR_LIT>" -> return ( a as IntArray ) . size <EOL> "<STR_LIT>" -> return ( a as FloatArray ) . size <EOL> "<STR_LIT>" -> return ( a as LongArray ) . size <EOL> "<STR_LIT>" -> return ( a as DoubleArray ) . size <EOL> "<STR_LIT>" -> return ( a as Array < Any ? > ) . size <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as BooleanArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as CharArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as ByteArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as ShortArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as IntArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as FloatArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as LongArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as DoubleArray ) . iterator ( ) <EOL> "<STR_LIT>" -> return ( a as Array < Any ? > ) . iterator ( ) <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return a ! ! <EOL> } <EOL> "<STR_LIT>" -> when ( type ) { <EOL> "<STR_LIT>" -> return ( a as Char ) . code <EOL> } <EOL> } <EOL> throw InterpreterMethodNotFoundError ( "<STR_LIT>" ) <EOL> }

/** This file is generated by `./gradlew generateInterpreterMap`. DO NOT MODIFY MANUALLY */


fun < T1 > Tuple1 < T1 > . splitAt0 ( ) : Tuple2 < EmptyTuple , Tuple1 < T1 > >

= Tuple2 < EmptyTuple , Tuple1 < T1 > > ( EmptyTuple , Tuple1 < T1 > ( this . _1 ( ) ) )

/**
 * Given a tuple `t(a1, ..., am)`, returns a [Tuple2] of the tuple `t(a1, ..., an)`
 * consisting of the first n elements, and the tuple `t(an+1, ..., am)` consisting
 * of the remaining elements.
 * Splitting at 0 or at n results in `t(t(), myTuple)` or `t(myTuple, t())` respectively.
 *
 * For example:
 * ```kotlin
 * t(1, 2, 3, 4, 5).splitAt2() == t(t(1, 2), t(3, 4, 5))
 * ```
 */


public operator fun String . rangeTo ( endInclusive : String ) : ColumnSet < * >

= <EOL> toColumnAccessor ( ) . rangeTo ( endInclusive . toColumnAccessor ( ) )

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `"fromColumn"`[`..`][String.rangeTo]`"toColumn"`}
 */


public operator fun String . rangeTo ( endInclusive : KProperty < * > ) : ColumnSet < * >

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `"fromColumn"`[`..`][String.rangeTo]`Type::toColumn`}
 */


public operator fun String . rangeTo ( endInclusive : AnyColumnReference ) : ColumnSet < * >

= <EOL> toColumnAccessor ( ) . rangeTo ( endInclusive )

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `"fromColumn"`[`..`][String.rangeTo]`toColumn`}
 */


public operator fun KProperty < * > . rangeTo ( endInclusive : String ) : ColumnSet < * >

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `Type::fromColumn`[`..`][KProperty.rangeTo]`"toColumn"`}
 */


public operator fun KProperty < * > . rangeTo ( endInclusive : KProperty < * > ) : ColumnSet < * >

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `Type::fromColumn`[`..`][KProperty.rangeTo]`Type::toColumn`}
 */


public operator fun KProperty < * > . rangeTo ( endInclusive : AnyColumnReference ) : ColumnSet < * >

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `Type::fromColumn`[`..`][KProperty.rangeTo]`toColumn`}
 */


public operator fun AnyColumnReference . rangeTo ( endInclusive : String ) : ColumnSet < * >

= <EOL> rangeTo ( endInclusive . toColumnAccessor ( ) )

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `fromColumn`[`..`][ColumnReference.rangeTo]`"toColumn"`}
 */


public operator fun AnyColumnReference . rangeTo ( endInclusive : KProperty < * > ) : ColumnSet < * >

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `fromColumn`[`..`][ColumnReference.rangeTo]`Type::toColumn`}
 */


public operator fun AnyColumnReference . rangeTo ( endInclusive : AnyColumnReference ) : ColumnSet < * >

= <EOL> createColumnSet { context -> <EOL> val startPath = this@rangeTo . resolveSingle ( context ) ! ! . path <EOL> val endPath = endInclusive . resolveSingle ( context ) ! ! . path <EOL> val parentPath = startPath . parent ( ) <EOL> val parentEndPath = endPath . parent ( ) <EOL> require ( parentPath == parentEndPath ) { <EOL> "<STR_LIT>" <EOL> } <EOL> val parentCol = context . df . getColumnGroup ( parentPath ! ! ) <EOL> val startIndex = parentCol . getColumnIndex ( startPath . name ) <EOL> val endIndex = parentCol . getColumnIndex ( endPath . name ) <EOL> require ( startIndex <= endIndex ) { "<STR_LIT>" } <EOL> ( startIndex .. endIndex ) . map { <EOL> parentCol . getColumn ( it ) . let { <EOL> it . addPath ( parentPath + it . name ) <EOL> } <EOL> } <EOL> }

/**
 * @include [CommonRangeOfColumnsDocs]
 * {@set [CommonRangeOfColumnsDocs.Example] `fromColumn`[`..`][ColumnReference.rangeTo]`toColumn`}
 */


fun attribute ( key : String , value : String )

{ <EOL> attrs [ key ] = value <EOL> }

/**
 * Appends an attribute to the generated podspec
 */


{ <EOL> statements . add ( statement ) <EOL> }

/**
 * Appends a statement 'as is' to the end of the generated podspec
 */


@ Suppress ( "<STR_LIT>" ) <EOL> inline fun < reified T : NativePointed > interpretNullablePointed ( ptr : NativePtr ) : T ?

{ <EOL> if ( ptr == nativeNullPtr ) { <EOL> return null <EOL> } else { <EOL> val result = nativeMemUtils . allocateInstance < T > ( ) <EOL> result . rawPtr = ptr <EOL> return result <EOL> } <EOL> }

/**
 * Returns interpretation of entity with given pointer, or `null` if it is null.
 *
 * @param T must not be abstract
 */


fun < T : CPointed > interpretCPointer ( rawValue : NativePtr )

= <EOL> if ( rawValue == nativeNullPtr ) { <EOL> null <EOL> } else { <EOL> CPointer < T > ( rawValue ) <EOL> }

/**
 * Creates a [CPointer] from the raw pointer of [NativePtr].
 *
 * @return a [CPointer] representation, or `null` if the [rawValue] represents native `nullptr`.
 */


fun ConeClassifierLookupTag . toSymbol ( useSiteSession : FirSession ) : FirClassifierSymbol < * > ?

= <EOL> when ( this ) { <EOL> is ConeClassLikeLookupTag -> toSymbol ( useSiteSession ) <EOL> is ConeClassifierLookupTagWithFixedSymbol -> this . symbol <EOL> else -> error ( "<STR_LIT>" ) <EOL> }

/**
 * Main operation on the [ConeClassifierLookupTag]
 *
 * Lookups the tag into its target within the given [useSiteSession]
 *
 * The second step of type refinement, see `/docs/fir/k2_kmp.md`
 *
 * @see ConeClassifierLookupTag
 */


@ OptIn ( LookupTagInternals :: class ) <EOL> fun ConeClassLikeLookupTag . toSymbol ( useSiteSession : FirSession ) : FirClassLikeSymbol < * > ?

{ <EOL> if ( this is ConeClassLookupTagWithFixedSymbol ) { <EOL> return this . symbol <EOL> } <EOL> ( this as? ConeClassLikeLookupTagImpl ) ? . boundSymbol ? . takeIf { it . first === useSiteSession } ? . let { return it . second } <EOL> return useSiteSession . symbolProvider . getClassLikeSymbolByClassId ( classId ) . also { <EOL> ( this as? ConeClassLikeLookupTagImpl ) ? . bindSymbolToLookupTag ( useSiteSession , it ) <EOL> } <EOL> }


fun ConeClassLikeLookupTag . toClassSymbol ( session : FirSession ) : FirClassSymbol < * > ?

= <EOL> toSymbol ( session ) as? FirClassSymbol < * >


fun ConeClassLikeLookupTag . toFirRegularClassSymbol ( session : FirSession ) : FirRegularClassSymbol ?

= <EOL> toSymbol ( session ) as? FirRegularClassSymbol


public fun detectPoses ( image : I , confidence : Float = <NUM_LIT> ) : MultiPoseDetectionResult

{ <EOL> val result = predict ( image ) <EOL> val filteredPoses = result . poses . filter { ( detectedObject , _ ) -> <EOL> detectedObject . probability > confidence <EOL> } <EOL> return MultiPoseDetectionResult ( filteredPoses ) <EOL> }

/**
 * Detects poses for the given [image] with the given [confidence].
 * @param [confidence] confidence value to use
 */


@ InternalCoroutinesApi <EOL> public fun MainDispatcherFactory . tryCreateDispatcher ( factories : List < MainDispatcherFactory > ) : MainCoroutineDispatcher

= <EOL> try { <EOL> createDispatcher ( factories ) <EOL> } catch ( cause : Throwable ) { <EOL> createMissingDispatcher ( cause , hintOnError ( ) ) <EOL> }

/**
 * If anything goes wrong while trying to create main dispatcher (class not found,
 * initialization failed, etc), then replace the main dispatcher with a special
 * stub that throws an error message on any attempt to actually use it.
 *
 * @suppress internal API
 */


@ InternalCoroutinesApi <EOL> public fun MainCoroutineDispatcher . isMissing ( ) : Boolean

= <EOL> this . immediate is MissingMainCoroutineDispatcher


@ ExternalKotlinTargetApi <EOL> fun < T : DecoratedExternalKotlinTarget > ExternalKotlinTargetDescriptor ( configure : ExternalKotlinTargetDescriptorBuilder < T > . ( ) -> Unit , ) : ExternalKotlinTargetDescriptor < T >

{ <EOL> return ExternalKotlinTargetDescriptorBuilder < T > ( ) . also ( configure ) . build ( ) <EOL> }

/**
 * Creates a new [ExternalKotlinTargetDescriptor] using the builder pattern.
 * There are some required properties that have to be set.
 * Check [ExternalKotlinTargetDescriptorBuilder] for further details.
 *
 * * The following properties have to be specified:
 * * - [ExternalKotlinTargetDescriptorBuilder.targetName]
 * * - [ExternalKotlinTargetDescriptorBuilder.platformType]
 * * - [ExternalKotlinTargetDescriptorBuilder.targetFactory]
 *
 * Not providing a required/necessary property will throw [IllegalStateException]
 */


fun configure ( action : ( T ) -> Unit )

{ <EOL> val configure = this . configure <EOL> if ( configure == null ) this . configure = action <EOL> else this . configure = { configure ( it ) ; action ( it ) } <EOL> }

/**
 * Generic configuration that will be invoked when building the target.
 * This configuration is called right after creating the instance and before
 * publishing the target to all subscribers of `kotlin.targets.all {}`
 */


fun configureIdeImport ( action : IdeMultiplatformImport . ( ) -> Unit )

{ <EOL> val configureIdeImport = this . configureIdeImport <EOL> if ( configureIdeImport == null ) this . configureIdeImport = action <EOL> else this . configureIdeImport = { configureIdeImport ( ) ; action ( ) } <EOL> }

/**
 * Main entrance of configuring the ide import:
 * The [IdeMultiplatformImport] instance passed to this function shall
 * not be captured and used outside of this block.
 *
 * The [IdeMultiplatformImport] instance shall not be retrieved any other way than using this function.
 */


fun create ( prefix : String , suffix : String = "<STR_LIT>" ) : File

= <EOL> File ( dir , "<STR_LIT>" )

/**
 * Create file named {name}{suffix} inside temporary dir
 */


fun processClassifiersByNameWithSubstitutionFromBothLevelsConditionally ( name : Name , processor : ( FirClassifierSymbol < * > , ConeSubstitutor ) -> Boolean , )

{ <EOL> var wasFoundAny = false <EOL> first . processClassifiersByNameWithSubstitution ( name ) { symbol , substitutor -> <EOL> wasFoundAny = processor ( symbol , substitutor ) <EOL> } <EOL> if ( ! wasFoundAny ) { <EOL> second . processClassifiersByNameWithSubstitution ( name , processor :: invoke ) <EOL> } <EOL> }

/**
 * Starts by querying [first] and calling [processor] with the results.
 * If [processor] doesn't return `true` for any of them (or no symbols were found), also queries [second] and calls [processor].
 */


@ InternalDokkaApi <EOL> fun AbstractDokkaTask . buildJsonConfiguration ( prettyPrint : Boolean = true ) : String

{ <EOL> val configuration = this . buildDokkaConfiguration ( ) <EOL> return if ( prettyPrint ) { <EOL> configuration . toPrettyJsonString ( ) <EOL> } else { <EOL> configuration . toCompactJsonString ( ) <EOL> } <EOL> }

/**
 * Serializes [DokkaConfiguration] of this [AbstractDokkaTask] as json
 *
 * Should be used for short-term debugging only, no guarantees are given for the support of this API.
 *
 * Better alternative should be introduced as part of [#2873](https://github.com/Kotlin/dokka/issues/2873).
 */


internal fun loadSequentialModelConfiguration ( configuration : File , inputShape : IntArray ? = null ) : Sequential

{ <EOL> val sequentialConfig = loadSerializedModel ( configuration ) <EOL> return deserializeSequentialModel ( sequentialConfig , inputShape ) <EOL> }

/**
 * Loads a [Sequential] model from json file with model configuration.
 *
 * @param [configuration] File containing model configuration.
 * @return Non-compiled and non-trained Sequential model.
 */


internal fun loadSequentialModelLayers ( config : KerasModel ? , inputShape : IntArray ? = null ) : Pair < Input , List < Layer > >

{ <EOL> val kerasLayers = config ! ! . config ! ! . layers ! ! <EOL> val input = createInputLayer ( kerasLayers . first ( ) , inputShape ) <EOL> val layers = kerasLayers . filter { ! it . class_name . equals ( LAYER_INPUT ) } . mapTo ( mutableListOf ( ) ) { <EOL> convertToLayer ( it ) <EOL> } <EOL> return Pair ( input , layers ) <EOL> }

/**
 * Loads a [Sequential] model layers from json file with model configuration.
 *
 * NOTE: This method is useful in transfer learning, when you need to manipulate on layers before building the Sequential model.
 *
 * @param config Model configuration.
 * @return Pair of <input layer; list of layers>.
 */


internal fun loadFunctionalModelConfiguration ( configuration : File , inputShape : IntArray ? = null ) : Functional

{ <EOL> val functionalConfig = loadSerializedModel ( configuration ) <EOL> return deserializeFunctionalModel ( functionalConfig , inputShape ) <EOL> }


internal fun loadFunctionalModelLayers ( config : KerasModel ? , inputShape : IntArray ? = null ) : List < Layer >

{ <EOL> val layers = mutableListOf < Layer > ( ) <EOL> val layersByNames = mutableMapOf < String , Layer > ( ) <EOL> val kerasLayers = config ! ! . config ! ! . layers ! ! <EOL> val input = createInputLayer ( kerasLayers . first ( ) , inputShape ) <EOL> layers . add ( input ) <EOL> layersByNames [ input . name ] = input <EOL> kerasLayers . forEach { <EOL> if ( ! it . class_name . equals ( LAYER_INPUT ) ) { <EOL> val layer = convertToLayer ( it , layersByNames ) <EOL> layers . add ( layer ) <EOL> layersByNames [ layer . name ] = layer <EOL> } <EOL> } <EOL> return layers <EOL> }

/**
 * Loads a [Functional] model layers from json file with model configuration.
 *
 * NOTE: This method is useful in transfer learning, when you need to manipulate on layers before building the Functional model.
 *
 * @param config Model configuration.
 * @return Pair of <input layer; list of layers>.
 */


private fun createInputLayer ( layer : KerasLayer , inputShape : IntArray ? = null ) : Input

{ <EOL> val inputLayerDims = if ( inputShape != null ) { <EOL> inputShape . map { it . toLong ( ) } . toLongArray ( ) <EOL> } else { <EOL> val batchInputShape = layer . config ! ! . batch_input_shape ! ! <EOL> batchInputShape . subList ( <NUM_LIT:1> , batchInputShape . size ) . map { it ! ! . toLong ( ) } . toLongArray ( ) <EOL> } <EOL> val inputLayerName = if ( layer . class_name . equals ( LAYER_INPUT ) ) layer . config ! ! . name ? : "<STR_LIT>" else "<STR_LIT>" <EOL> return Input ( * inputLayerDims , name = inputLayerName ) <EOL> }

/**
 * The layer creator functions should be put below.
 */


protected fun incrementInductionVariable ( builder : DeclarationIrBuilder ) : IrStatement

= with ( builder ) { <EOL> with ( headerInfo . progressionType ) { <EOL> val stepType = stepClass . defaultType <EOL> val plusFun = elementClass . defaultType . getClass ( ) ! ! . functions . single { <EOL> it . name == OperatorNameConventions . PLUS && <EOL> it . valueParameters . size == <NUM_LIT:1> && <EOL> it . valueParameters [ <NUM_LIT:0> ] . type == stepType <EOL> } <EOL> irSet ( inductionVariable . symbol , irCallOp ( plusFun . symbol , plusFun . returnType , irGet ( inductionVariable ) , stepExpression . shallowCopy ( ) , IrStatementOrigin . PLUSEQ ) , IrStatementOrigin . PLUSEQ ) <EOL> } <EOL> }

/** Statement used to increment the induction variable. */


override fun < T > injectCoroutineContext ( publisher : Publisher < T > , coroutineContext : CoroutineContext ) : Publisher < T >

{ <EOL> val reactorContext = coroutineContext [ ReactorContext ] ? . context ? : return publisher <EOL> return when ( publisher ) { <EOL> is Mono -> publisher . contextWrite ( reactorContext ) <EOL> is Flux -> publisher . contextWrite ( reactorContext ) <EOL> else -> publisher <EOL> } <EOL> }

/**
 * Injects all values from the [ReactorContext] entry of the given coroutine context
 * into the downstream [Context] of Reactor's [Publisher] instances of [Mono] or [Flux].
 */


public abstract fun forward ( tf : Ops , input : Operand < Float > ) : Operand < Float >

/**
 * Applies the activation functions to the [input] to produce the output.
 *
 * @param [tf] TensorFlow graph API for building operations.
 * @param [input] TensorFlow graph leaf node representing layer output before activation function.
 */


fun isAllowed ( qualifiedName : String ) : Boolean

/**
 * @return **true** if an annotations with [qualifiedName] is allowed
 */


fun filtered ( annotations : Collection < PsiAnnotation > ) : Collection < PsiAnnotation >

/**
 * @return a filtered collection where each annotation in a list has an allowed qualifier
 */


public expect inline fun < reified T > Array < out T > ? . orEmpty ( ) : Array < out T >

/**
 * Returns the array if it's not `null`, or an empty array otherwise.
 * @sample samples.collections.Arrays.Usage.arrayOrEmpty
 */


public expect inline fun < reified T > Collection < T > . toTypedArray ( ) : Array < T >

/**
 * Returns a *typed* array containing all the elements of this collection.
 *
 * Allocates an array of runtime type `T` having its size equal to the size of this collection
 * and populates the array with the elements of this collection.
 * @sample samples.collections.Collections.Collections.collectionToTypedArray
 */


@ SinceKotlin ( "<STR_LIT:1.2>" ) <EOL> public expect fun < T > MutableList < T > . fill ( value : T ) : Unit

/**
 * Fills the list with the provided [value].
 *
 * Each element in the list gets replaced with the [value].
 */


@ SinceKotlin ( "<STR_LIT:1.2>" ) <EOL> public expect fun < T > MutableList < T > . shuffle ( ) : Unit

/**
 * Randomly shuffles elements in this list.
 *
 * See: https://en.wikipedia.org/wiki/Fisher%E2%80%93Yates_shuffle#The_modern_algorithm
 */


@ SinceKotlin ( "<STR_LIT:1.2>" ) <EOL> public expect fun < T > Iterable < T > . shuffled ( ) : List < T >

/**
 * Returns a new list with the elements of this collection randomly shuffled.
 */


public expect fun < T : Comparable < T > > MutableList < T > . sort ( ) : Unit

/**
 * Sorts elements in the list in-place according to their natural sort order.
 *
 * The sort is _stable_. It means that equal elements preserve their order relative to each other after sorting.
 *
 * @sample samples.collections.Collections.Sorting.sortMutableList
 */


public expect fun < T > MutableList < T > . sortWith ( comparator : Comparator < in T > ) : Unit

/**
 * Sorts elements in the list in-place according to the order specified with [comparator].
 *
 * The sort is _stable_. It means that equal elements preserve their order relative to each other after sorting.
 *
 * @sample samples.collections.Collections.Sorting.sortMutableListWith
 */


fun filtersPlot ( conv2DLayer : Conv2D , plotFeature : PlotFeature = PlotFeature . GRAY , imageSize : Int = <NUM_LIT> , columns : Int = <NUM_LIT:8> ) : Figure

{ <EOL> @ Suppress ( "<STR_LIT:UNCHECKED_CAST>" ) <EOL> val weights = conv2DLayer . weights . values . toTypedArray ( ) [ <NUM_LIT:0> ] as TensorImageData <EOL> val xyInOut = extractXYInputOutputAxeSizes ( weights , FILTER_LAYERS_PERMUTATION ) <EOL> val plots = cartesianProductIndices ( xyInOut [ <NUM_LIT:2> ] , xyInOut [ <NUM_LIT:3> ] ) . map { ( i , o ) -> <EOL> xyPlot ( xyInOut [ <NUM_LIT:0> ] , xyInOut [ <NUM_LIT:1> ] , plotFeature ) { x , y -> <EOL> weights [ y ] [ x ] [ i ] [ o ] <EOL> } <EOL> } <EOL> return columnPlot ( plots , columns , imageSize ) <EOL> }

/**
 * Create a column plot of tile plots for weights of Conv2D layer filters.
 *
 * @param conv2DLayer which weights will be changed to tile plot
 * @param plotFeature filling colors of the created plot
 * @param imageSize size of width and height of single plot in px
 * @param columns number of columns in which the single filters plots are arranged
 * @return a figure representing the weights plots
 */


fun modelActivationOnLayersPlot ( model : TrainableModel , x : FloatData , plotFeature : PlotFeature = PlotFeature . GRAY , imageSize : Int = <NUM_LIT> , columns : Int = <NUM_LIT:8> , ) : List < Figure >

{ <EOL> val activations = model . predictAndGetActivations ( x ) . second <EOL> @ Suppress ( "<STR_LIT:UNCHECKED_CAST>" ) <EOL> val activationArrays = activations . mapNotNull { it as? TensorImageData } <EOL> return activationArrays . map { weights -> <EOL> val xyInOut = extractXYInputOutputAxeSizes ( weights , ACTIVATION_LAYERS_PERMUTATION ) <EOL> val plots = cartesianProductIndices ( xyInOut [ <NUM_LIT:2> ] , xyInOut [ <NUM_LIT:3> ] ) . map { ( i , o ) -> <EOL> xyPlot ( xyInOut [ <NUM_LIT:0> ] , xyInOut [ <NUM_LIT:1> ] , plotFeature ) { x , y -> <EOL> weights [ i ] [ y ] [ x ] [ o ] <EOL> } <EOL> } <EOL> columnPlot ( plots , columns , imageSize ) <EOL> } <EOL> }

/**
 * Create a list of columns plots for model activation on layers.
 * The model is evaluated on given input and the obtained activations arrays
 * of the following layers are converted into separated figures with columns
 * plots of the weights for the filters in [Conv2D] layers
 *
 * @param model that is evaluated to get the activations on its weights
 * @param x input for model evaluation
 * @param plotFeature filling colors of the created plot
 * @param imageSize size of width and height of single plot in px
 * @param columns number of columns in which the single filters plots are arranged
 * @return list of figures representing the activations plots for model evaluation
 */


{ <EOL> assertSame ( Dispatchers . Swing , Dispatchers . Main ) <EOL> }

/** Tests that the Main dispatcher is in fact the JavaFx one. */


@ Suppress ( "<STR_LIT>" ) <EOL> fun FirDeclarationCollector < FirBasedSymbol < * > > . collectTopLevel ( file : FirFile , packageMemberScope : FirPackageMemberScope )

{ <EOL> for ( ( declarationName , group ) in groupTopLevelByName ( file . declarations , context ) ) { <EOL> val groupHasClassLikesOrProperties = group . classLikes . isNotEmpty ( ) || group . properties . isNotEmpty ( ) <EOL> val groupHasSimpleFunctions = group . simpleFunctions . isNotEmpty ( ) <EOL> fun collect ( declarations : List < Pair < FirBasedSymbol < * > , String > > , conflictingSymbol : FirBasedSymbol < * > , conflictingPresentation : String ? = null , conflictingFile : FirFile ? = null , ) { <EOL> for ( ( declaration , declarationPresentation ) in declarations ) { <EOL> collectTopLevelConflict ( declaration , declarationPresentation , file , conflictingSymbol , conflictingPresentation , conflictingFile ) <EOL> session . lookupTracker ? . recordNameLookup ( declarationName , file . packageFqName . asString ( ) , declaration . source , file . source ) <EOL> } <EOL> } <EOL> fun collectFromClassifierSource ( conflictingSymbol : FirClassifierSymbol < * > , conflictingPresentation : String ? = null , conflictingFile : FirFile ? = null , ) { <EOL> collect ( group . classLikes , conflictingSymbol , conflictingPresentation , conflictingFile ) <EOL> collect ( group . properties , conflictingSymbol , conflictingPresentation , conflictingFile ) <EOL> if ( groupHasSimpleFunctions ) { <EOL> if ( conflictingSymbol !is FirClassLikeSymbol < * > ) { <EOL> return <EOL> } <EOL> conflictingSymbol . expandedClassWithConstructorsScope ( context ) ? . let { ( expandedClass , scopeWithConstructors ) -> <EOL> if ( expandedClass . classKind == ClassKind . OBJECT || expandedClass . classKind == ClassKind . ENUM_ENTRY ) { <EOL> return <EOL> } <EOL> scopeWithConstructors . processDeclaredConstructors { constructor -> <EOL> val ctorRepresentation = FirRedeclarationPresenter . represent ( constructor , conflictingSymbol ) <EOL> collect ( group . simpleFunctions , conflictingSymbol = constructor , conflictingPresentation = ctorRepresentation ) <EOL> } <EOL> } <EOL> } <EOL> } <EOL> if ( groupHasSimpleFunctions || group . constructors . isNotEmpty ( ) ) { <EOL> packageMemberScope . processFunctionsByName ( declarationName ) { <EOL> collect ( group . simpleFunctions , it ) <EOL> collect ( group . constructors , it ) <EOL> } <EOL> } <EOL> if ( groupHasClassLikesOrProperties || groupHasSimpleFunctions ) { <EOL> packageMemberScope . processClassifiersByNameWithSubstitution ( declarationName ) { symbol , _ -> <EOL> collectFromClassifierSource ( conflictingSymbol = symbol ) <EOL> } <EOL> session . nameConflictsTracker ? . let { it as? FirNameConflictsTracker } <EOL> ? . redeclaredClassifiers ? . get ( ClassId ( file . packageFqName , declarationName ) ) ? . forEach { <EOL> collectFromClassifierSource ( conflictingSymbol = it . classifier , conflictingFile = it . file ) <EOL> } <EOL> for ( ( classLike , representation ) in group . classLikes ) { <EOL> collectFromClassifierSource ( classLike , conflictingPresentation = representation , conflictingFile = file ) <EOL> } <EOL> } <EOL> if ( groupHasClassLikesOrProperties || group . extensionProperties . isNotEmpty ( ) ) { <EOL> packageMemberScope . processPropertiesByName ( declarationName ) { <EOL> collect ( group . classLikes , conflictingSymbol = it ) <EOL> collect ( group . properties , conflictingSymbol = it ) <EOL> collect ( group . extensionProperties , conflictingSymbol = it ) <EOL> } <EOL> } <EOL> } <EOL> }

/**
 * To check top-level declarations for redeclarations, we check multiple sources (the packageMemberScope's properties, functions
 * and classifiers), redeclared classifiers from session.nameConflictsTracker and the file's declarations themselves.
 * To prevent inspecting the same source multiple times, we group the declarations in the file by name and subdivide them into
 * buckets (the properties of DeclarationGroup).
 *
 * Depending on the presence of declarations in the buckets, some checks can be omitted.
 * E.g., if there are no functions and no classes with constructors in the file, we don't need to inspect functions.
 *
 * #### Matrix of possible conflicts between "sources" and "buckets"
 *
 * | | simpleFunctions | constructors | classLikes | Properties | extensionProperties |
 * |-------------------------|-----------------|--------------|------------|------------|---------------------|
 * | functions | X | X | | | |
 * | classifiers | | | X | X | |
 * | constructors of classes | X | | | | |
 * | properties | | | X | X | X |
 */


fun checkForLocalRedeclarations ( elements : List < FirElement > , context : CheckerContext , reporter : DiagnosticReporter )

{ <EOL> if ( elements . size <= <NUM_LIT:1> ) return <EOL> val multimap = ListMultimap < Name , FirBasedSymbol < * > > ( ) <EOL> for ( element in elements ) { <EOL> val name : Name ? <EOL> val symbol : FirBasedSymbol < * > ? <EOL> when ( element ) { <EOL> is FirVariable -> { <EOL> symbol = element . symbol <EOL> name = element . name <EOL> } <EOL> is FirOuterClassTypeParameterRef -> { <EOL> continue <EOL> } <EOL> is FirTypeParameterRef -> { <EOL> symbol = element . symbol <EOL> name = symbol . name <EOL> } <EOL> else -> { <EOL> symbol = null <EOL> name = null <EOL> } <EOL> } <EOL> if ( name ? . isSpecial == false ) { <EOL> multimap . put ( name , symbol ! ! ) <EOL> } <EOL> } <EOL> for ( key in multimap . keys ) { <EOL> val conflictingElements = multimap [ key ] <EOL> if ( conflictingElements . size > <NUM_LIT:1> ) { <EOL> for ( conflictingElement in conflictingElements ) { <EOL> reporter . reportOn ( conflictingElement . source , FirErrors . REDECLARATION , conflictingElements , context ) <EOL> } <EOL> } <EOL> } <EOL> }

/** Checks for redeclarations of value and type parameters, and local variables. */


private fun resolveJvmSourceSets ( sourceSet : KotlinSourceSet ) : Iterable < IdeaKotlinDependency >

{ <EOL> return IdeBinaryDependencyResolver ( binaryType = IdeaKotlinBinaryDependency . KOTLIN_COMPILE_BINARY_TYPE , artifactResolutionStrategy = IdeBinaryDependencyResolver . ArtifactResolutionStrategy . PlatformLikeSourceSet ( setupPlatformResolutionAttributes = { <EOL> sourceSet . internal . compilations . filter { it . platformType == KotlinPlatformType . jvm } <EOL> . map { compilation -> compilation . internal . configurations . compileDependencyConfiguration . attributes } <EOL> . map { attributes -> attributes . toMap ( ) . toList ( ) . toSet ( ) } <EOL> . reduceOrNull { acc , next -> acc intersect next } <EOL> . orEmpty ( ) <EOL> . forEach { ( key , value ) -> <EOL> @ Suppress ( "<STR_LIT:UNCHECKED_CAST>" ) <EOL> setAttributeProvider ( sourceSet . project , key as Attribute < Any > ) { value as Any } <EOL> } <EOL> } , componentFilter = { id -> id is ProjectComponentIdentifier } ) ) . resolve ( sourceSet ) <EOL> }

/**
 * Pretend that this [sourceSet] is 'jvm' and resolve binaries.
 * #### Setting up attributes:
 * In order to set up the 'platform like' / 'jvm like' dependency resolution, this algorithm
 * will look at all 'jvm' based compilations, uses their 'compileDependencyConfiguration' as reference and
 * then uses the intersection of all available attributes
 *
 * #### componentFilter:
 * This resolver will just care about resolving project dependencies.
 * Therefore, a componentFilter is added to only resolve project dependencies.
 * We expect to resolve project artifact dependencies which can then be matched to the corresponding
 * SourceSets on IDE side.
 */


public fun < I , O > Operation < I , O > . onResult ( block : ( O ) -> Unit ) : Operation < I , O >

{ <EOL> return PreprocessingPipeline ( this , object : Operation < O , O > { <EOL> override fun apply ( input : O ) : O { <EOL> block ( input ) <EOL> return input <EOL> } <EOL> override fun getOutputShape ( inputShape : TensorShape ) : TensorShape = inputShape <EOL> } ) <EOL> }

/**
 * Convenience functions for executing custom logic after applying [Operation].
 * Could be useful for debugging purposes.
 */


public fun < I , M , O > Operation < I , M > . call ( operation : Operation < M , O > ) : Operation < I , O >

{ <EOL> return PreprocessingPipeline ( this , operation ) <EOL> }

/**
 * Applies provided [operation] to the preprocessing pipeline.
 */


internal actual fun String . nativeIndexOf ( ch : Char , fromIndex : Int ) : Int

{ <EOL> for ( index in fromIndex . coerceAtLeast ( <NUM_LIT:0> ) .. this . lastIndex ) { <EOL> if ( ch == get ( index ) ) return index <EOL> } <EOL> return - <NUM_LIT:1> <EOL> }

/**
 * Returns the index within this string of the first occurrence of the specified character, starting from the specified offset.
 */


internal actual fun String . nativeLastIndexOf ( ch : Char , fromIndex : Int ) : Int

{ <EOL> for ( index in fromIndex . coerceAtMost ( this . lastIndex ) downTo <NUM_LIT:0> ) { <EOL> if ( ch == get ( index ) ) return index <EOL> } <EOL> return - <NUM_LIT:1> <EOL> }

/**
 * Returns the index within this string of the last occurrence of the specified character.
 */


internal actual fun String . nativeIndexOf ( str : String , fromIndex : Int ) : Int

{ <EOL> for ( index in fromIndex . coerceAtLeast ( <NUM_LIT:0> ) .. ( this . length - str . length ) ) { <EOL> if ( str . regionMatchesImpl ( <NUM_LIT:0> , this , index , str . length , false ) ) { <EOL> return index <EOL> } <EOL> } <EOL> return - <NUM_LIT:1> <EOL> }

/**
 * Returns the index within this string of the first occurrence of the specified substring, starting from the specified offset.
 */


internal actual fun String . nativeLastIndexOf ( str : String , fromIndex : Int ) : Int

{ <EOL> for ( index in fromIndex . coerceAtMost ( this . length - str . length ) downTo <NUM_LIT:0> ) { <EOL> if ( str . regionMatchesImpl ( <NUM_LIT:0> , this , index , str . length , false ) ) { <EOL> return index <EOL> } <EOL> } <EOL> return - <NUM_LIT:1> <EOL> }

/**
 * Returns the index within this string of the last occurrence of the specified character, starting from the specified offset.
 */


@ SinceKotlin ( "<STR_LIT:1.2>" ) <EOL> @ Deprecated ( "<STR_LIT>" , ReplaceWith ( "<STR_LIT>" ) ) <EOL> @ DeprecatedSinceKotlin ( warningSince = "<STR_LIT:1.4>" , errorSince = "<STR_LIT:1.5>" ) <EOL> public actual fun String ( chars : CharArray ) : String

= <EOL> chars . concatToString ( )

/**
 * Converts the characters in the specified array to a string.
 */


@ SinceKotlin ( "<STR_LIT:1.2>" ) <EOL> @ Deprecated ( "<STR_LIT>" , ReplaceWith ( "<STR_LIT>" ) ) <EOL> @ DeprecatedSinceKotlin ( warningSince = "<STR_LIT:1.4>" , errorSince = "<STR_LIT:1.5>" ) <EOL> public actual fun String ( chars : CharArray , offset : Int , length : Int ) : String

{ <EOL> if ( offset < <NUM_LIT:0> || length < <NUM_LIT:0> || offset + length > chars . size ) <EOL> throw IndexOutOfBoundsException ( ) <EOL> val copy = WasmCharArray ( length ) <EOL> copyWasmArray ( chars . storage , copy , offset , <NUM_LIT:0> , length ) <EOL> return copy . createString ( ) <EOL> }

/**
 * Converts the characters from a portion of the specified array to a string.
 *
 * @throws IndexOutOfBoundsException if either [offset] or [length] are less than zero
 * or `offset + length` is out of [chars] array bounds.
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> public actual fun CharArray . concatToString ( ) : String

{ <EOL> val thisStorage = this . storage <EOL> val thisLength = thisStorage . len ( ) <EOL> val copy = WasmCharArray ( thisLength ) <EOL> copyWasmArray ( this . storage , copy , <NUM_LIT:0> , <NUM_LIT:0> , thisLength ) <EOL> return copy . createString ( ) <EOL> }

/**
 * Concatenates characters in this [CharArray] into a String.
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun CharArray . concatToString ( startIndex : Int = <NUM_LIT:0> , endIndex : Int = this . size ) : String

{ <EOL> AbstractList . checkBoundsIndexes ( startIndex , endIndex , this . size ) <EOL> val length = endIndex - startIndex <EOL> val copy = WasmCharArray ( length ) <EOL> copyWasmArray ( this . storage , copy , startIndex , <NUM_LIT:0> , length ) <EOL> return copy . createString ( ) <EOL> }

/**
 * Concatenates characters in this [CharArray] or its subrange into a String.
 *
 * @param startIndex the beginning (inclusive) of the subrange of characters, 0 by default.
 * @param endIndex the end (exclusive) of the subrange of characters, size of this array by default.
 *
 * @throws IndexOutOfBoundsException if [startIndex] is less than zero or [endIndex] is greater than the size of this array.
 * @throws IllegalArgumentException if [startIndex] is greater than [endIndex].
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> public actual fun String . toCharArray ( ) : CharArray

{ <EOL> val thisChars = this . chars <EOL> val thisLength = thisChars . len ( ) <EOL> val newArray = CharArray ( thisLength ) <EOL> copyWasmArray ( thisChars , newArray . storage , <NUM_LIT:0> , <NUM_LIT:0> , thisLength ) <EOL> return newArray <EOL> }

/**
 * Returns a [CharArray] containing characters of this string.
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun String . toCharArray ( startIndex : Int = <NUM_LIT:0> , endIndex : Int = this . length ) : CharArray

{ <EOL> AbstractList . checkBoundsIndexes ( startIndex , endIndex , length ) <EOL> val newLength = endIndex - startIndex <EOL> val newArray = CharArray ( newLength ) <EOL> copyWasmArray ( this . chars , newArray . storage , startIndex , <NUM_LIT:0> , newLength ) <EOL> return newArray <EOL> }

/**
 * Returns a [CharArray] containing characters of this string or its substring.
 *
 * @param startIndex the beginning (inclusive) of the substring, 0 by default.
 * @param endIndex the end (exclusive) of the substring, length of this string by default.
 *
 * @throws IndexOutOfBoundsException if [startIndex] is less than zero or [endIndex] is greater than the length of this string.
 * @throws IllegalArgumentException if [startIndex] is greater than [endIndex].
 */


@ SinceKotlin ( "<STR_LIT:2.0>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun String . toCharArray ( destination : CharArray , destinationOffset : Int = <NUM_LIT:0> , startIndex : Int = <NUM_LIT:0> , endIndex : Int = length ) : CharArray

{ <EOL> AbstractList . checkBoundsIndexes ( startIndex , endIndex , length ) <EOL> val rangeSize = endIndex - startIndex <EOL> AbstractList . checkBoundsIndexes ( destinationOffset , destinationOffset + rangeSize , destination . size ) <EOL> copyWasmArray ( this . chars , destination . storage , startIndex , destinationOffset , rangeSize ) <EOL> return destination <EOL> }

/**
 * Copies characters from this string into the [destination] character array and returns that array.
 *
 * @param destination the array to copy to.
 * @param destinationOffset the position in the array to copy to.
 * @param startIndex the start offset (inclusive) of the substring to copy.
 * @param endIndex the end offset (exclusive) of the substring to copy.
 *
 * @throws IndexOutOfBoundsException or [IllegalArgumentException] when [startIndex] or [endIndex] is out of range of this string builder indices or when `startIndex > endIndex`.
 * @throws IndexOutOfBoundsException when the subrange doesn't fit into the [destination] array starting at the specified [destinationOffset],
 * or when that index is out of the [destination] array indices range.
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> public actual fun ByteArray . decodeToString ( ) : String

{ <EOL> return decodeUtf8 ( this , <NUM_LIT:0> , size , false ) <EOL> }

/**
 * Decodes a string from the bytes in UTF-8 encoding in this array.
 *
 * Malformed byte sequences are replaced by the replacement char `\uFFFD`.
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> @ Suppress ( "<STR_LIT:ACTUAL_FUNCTION_WITH_DEFAULT_ARGUMENTS>" ) <EOL> public actual fun ByteArray . decodeToString ( startIndex : Int = <NUM_LIT:0> , endIndex : Int = this . size , throwOnInvalidSequence : Boolean = false ) : String

{ <EOL> AbstractList . checkBoundsIndexes ( startIndex , endIndex , this . size ) <EOL> return decodeUtf8 ( this , startIndex , endIndex , throwOnInvalidSequence ) <EOL> }

/**
 * Decodes a string from the bytes in UTF-8 encoding in this array or its subrange.
 *
 * @param startIndex the beginning (inclusive) of the subrange to decode, 0 by default.
 * @param endIndex the end (exclusive) of the subrange to decode, size of this array by default.
 * @param throwOnInvalidSequence specifies whether to throw an exception on malformed byte sequence or replace it by the replacement char `\uFFFD`.
 *
 * @throws IndexOutOfBoundsException if [startIndex] is less than zero or [endIndex] is greater than the size of this array.
 * @throws IllegalArgumentException if [startIndex] is greater than [endIndex].
 * @throws CharacterCodingException if the byte array contains malformed UTF-8 byte sequence and [throwOnInvalidSequence] is true.
 */


@ SinceKotlin ( "<STR_LIT:1.4>" ) <EOL> public actual fun String . encodeToByteArray ( ) : ByteArray

{ <EOL> return encodeUtf8 ( this , <NUM_LIT:0> , length , false ) <EOL> }

/**
 * Encodes this string to an array of bytes in UTF-8 encoding.
 *
 * Any malformed char sequence is replaced by the replacement byte sequence.
 */