We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If compound extensions do make their way into Kotlin, we could leverage them nicely in AutoDispose to do something like this:
fun <T> ScopeProvider.Observable<T>.autoDispose() { // ... } fun test(scope: ScopeProvider) = scope.apply { myObservable .autoDisposable() .subscribe() } // or class Worker : ScopeProvider { fun run() { workObservable .autoDisposable() .subscribe() } }
The text was updated successfully, but these errors were encountered:
Note: this would supersede the need for #375
Sorry, something went wrong.
Closing this as it seems like it's not moving anywhere
context receivers are happening
Should be a very simple function:
// Original function @CheckReturnValue inline fun <T> Observable<T>.autoDispose(provider: ScopeProvider): ObservableSubscribeProxy<T> = this.`as`(AutoDispose.autoDisposable(provider)) // Context receivers function context(ScopeProvider) inline fun <T> Observable<T>.autoDispose(): ObservableSubscribeProxy<T> = autoDispose(this@ScopeProvider)
No branches or pull requests
If compound extensions do make their way into Kotlin, we could leverage them nicely in AutoDispose to do something like this:
The text was updated successfully, but these errors were encountered: