Remove redundant crossinline (#4348)
Seems we don't need them in newer Kotlin.
This commit is contained in:
parent
af016c1766
commit
ba495f41a5
3 changed files with 3 additions and 3 deletions
|
@ -38,7 +38,7 @@ sealed interface Either<out L, out R> {
|
|||
fun asRight(): R = (this as Right<L, R>).value
|
||||
|
||||
companion object {
|
||||
inline fun <L, R, N> Either<L, R>.map(crossinline mapper: (R) -> N): Either<L, N> {
|
||||
inline fun <L, R, N> Either<L, R>.map(mapper: (R) -> N): Either<L, N> {
|
||||
return if (this.isLeft()) {
|
||||
Left(this.asLeft())
|
||||
} else {
|
||||
|
|
|
@ -118,7 +118,7 @@ class AccountsInListViewModel @Inject constructor(private val api: MastodonApi)
|
|||
}
|
||||
}
|
||||
|
||||
private inline fun updateState(crossinline fn: State.() -> State) {
|
||||
private inline fun updateState(fn: State.() -> State) {
|
||||
_state.value = fn(_state.value)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -143,7 +143,7 @@ internal class ListsViewModel @Inject constructor(private val api: MastodonApi)
|
|||
}
|
||||
}
|
||||
|
||||
private inline fun updateState(crossinline fn: State.() -> State) {
|
||||
private inline fun updateState(fn: State.() -> State) {
|
||||
_state.value = fn(_state.value)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue