Finalize bytecode-only lambdas and frame binding

This commit is contained in:
sergeych committed 2026-02-12 17:47:05 +03:00
1 parent a481371349
commit db4f7d0973
14 files changed
+653 -314

No files matched your search

+10 -2
View File
@@ -31,6 +31,12 @@ extern class List<T> : Array<T> {
fun add(value: T, more...): Void
}
extern class RingBuffer<T> : Iterable<T> {
val size: Int
fun first(): T
fun add(value: T): Void
}
extern class Set<T> : Collection<T> {
}
@@ -270,8 +276,10 @@ fun Iterable<T>.shuffled(): List<T> {
*/
fun Iterable<Iterable<T>>.flatten(): List<T> {
var result: List<T> = List()
forEach { i ->
i.forEach { result += it }
for (i in this) {
for (item in i) {
result += item
}
}
result
}