KT-31741: stdlib: DeepRecursiveFunction (#3398)

Introduces experimental coroutines-based framework to execute deeply recursive functions that utilities the heap and thus avoid StackOverflowError.
This commit is contained in:
Roman Elizarov
2020-05-27 10:06:00 +03:00
committed by GitHub
parent 9fa1614903
commit 46b426ef77
7 changed files with 400 additions and 0 deletions
@@ -1,6 +1,20 @@
public abstract interface annotation class kotlin/BuilderInference : java/lang/annotation/Annotation {
}
public final class kotlin/DeepRecursiveFunction {
public fun <init> (Lkotlin/jvm/functions/Function3;)V
}
public final class kotlin/DeepRecursiveKt {
public static final fun invoke (Lkotlin/DeepRecursiveFunction;Ljava/lang/Object;)Ljava/lang/Object;
}
public abstract class kotlin/DeepRecursiveScope {
public abstract fun callRecursive (Ljava/lang/Object;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public abstract fun callRecursive (Lkotlin/DeepRecursiveFunction;Ljava/lang/Object;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public final fun invoke (Lkotlin/DeepRecursiveFunction;Ljava/lang/Object;)Ljava/lang/Void;
}
public abstract interface annotation class kotlin/Deprecated : java/lang/annotation/Annotation {
public abstract fun level ()Lkotlin/DeprecationLevel;
public abstract fun message ()Ljava/lang/String;