max.cruz
11/11/2020, 1:18 AMval scope = CoroutineScope(Dispatchers.Main + SupervisorJob())
...
scope.launch {
val something = withContext(Dispatchers.Default) { suspendCall() }
println(something)
}
Works fine in Andorid but in iOS I get:
Uncaught Kotlin exception: kotlin.native.IncorrectDereferenceException: illegal attempt to access non-shared <object>@3faca88 from other thread
max.cruz
11/11/2020, 1:20 AMwithContext(Dispatchers.Default) { suspendCall() }
should complete the call in the Default dispatcher and then the usages inside of the Man scope should not be a problem. Any clues 😓?kpgalligan
11/11/2020, 2:45 PMmax.cruz
11/16/2020, 8:59 AMmax.cruz
11/16/2020, 9:01 AM