DeepRecursiveScope

Common
JVM
JS
Native
1.7
sealed class DeepRecursiveScope<T, R>
(source)

A scope class for DeepRecursiveFunction function declaration that defines callRecursive methods to recursively call this function or another DeepRecursiveFunction putting the call activation frame on the heap.

Parameters

T - function parameter type.

R - function result type.

Functions

Common
JVM
JS
Native
1.0

callRecursive

Makes recursive call to this DeepRecursiveFunction function putting the call activation frame on the heap, as opposed to the actual call stack that is used by a regular recursive call.

abstract suspend fun callRecursive(value: T): R

Makes call to the specified DeepRecursiveFunction function putting the call activation frame on the heap, as opposed to the actual call stack that is used by a regular call.

abstract suspend fun <U, S> DeepRecursiveFunction<U, S>.callRecursive(
    value: U
): S
Common
JVM
JS
Native
1.0

invoke

operator fun DeepRecursiveFunction<*, *>.invoke(
    value: Any?
): Nothing