Ran Magen
10/01/2019, 10:42 PMcoroutineScope
that ends up doing nothing. For example should I bother writing:
if (collection.isNotEmpty()) {
coroutineScope {
collection.forEach { item -> launch { doSomeComplexSuspendingWork(item) } }
}
}
Or does it not really matter much and this would be just as efficient (and cleaner to read)
coroutineScope {
collection.forEach { item -> launch { doSomeComplexSuspendingWork(item) } }
}
octylFractal
10/01/2019, 10:57 PMlouiscad
10/01/2019, 11:10 PM