https://kotlinlang.org logo
Title
t

travis

09/20/2018, 6:33 PM
In the structured concurrency example for Android (https://github.com/Kotlin/kotlinx.coroutines/blob/master/ui/coroutines-guide-ui.md#structured-concurrency-lifecycle-and-coroutine-parent-child-hierarchy),
Dispatchers.Main
is added to the
job
to make it so the dispatcher used for child coroutine builders will be
Dispatchers.Main
(correct me if I'm wrong). Which dispatcher is used if the
+ Dispatchers.Main
portion is omitted?
override val coroutineContext: CoroutineContext 
    get() = job
e

elizarov

09/20/2018, 9:49 PM
The default one is used by default
👌 1
t

travis

09/20/2018, 9:52 PM
That's what I speculated but it wasn't immediately obvious looking through the source code. Thanks for confirming!