I'm trying to dig into the internal implementation...
# coroutines
m
I'm trying to dig into the internal implementation of JVM coroutines. How a coroutine block (instantiated as
SuspendLambda
resumes its execution after last suspension point when
invokeSuspend
is called again? Is the magic field
L$0
inside
SuspendLambda
responsible for this? I'm working with a dead-simple snippet to understand the inner workings:
Copy code
fun main() {
  val i = runBlocking {
    delay(1000)
    1
  }
  println(i)
}
s
Would love to understand this. Writing a blog about it ?