Merge pull request #3283 from element-hq/renovate/kotlin

Update kotlin
This commit is contained in:
Benoit Marty 2024-10-31 08:45:43 +01:00 committed by GitHub
commit c11a503710
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 18 additions and 9 deletions

View file

@ -7,6 +7,7 @@
package io.element.android.libraries.core.coroutine
import kotlinx.coroutines.ExperimentalForInheritanceCoroutinesApi
import kotlinx.coroutines.coroutineScope
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.FlowCollector
@ -19,6 +20,7 @@ import kotlinx.coroutines.flow.stateIn
* A [StateFlow] that derives its value from a [Flow].
* Useful when you want to apply transformations to a [Flow] and expose it as a [StateFlow].
*/
@OptIn(ExperimentalForInheritanceCoroutinesApi::class)
class DerivedStateFlow<T>(
private val getValue: () -> T,
private val flow: Flow<T>