Skip to content
New issue

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

ScopeProvider -> CoroutineScope interop #371

Closed
ZacSweers opened this issue Sep 6, 2019 · 0 comments · Fixed by #374
Closed

ScopeProvider -> CoroutineScope interop #371

ZacSweers opened this issue Sep 6, 2019 · 0 comments · Fixed by #374

Comments

@ZacSweers
Copy link
Collaborator

Can we do something like this?

fun CoroutineScope.asScopeProvider(): ScopeProvider

fun ScopeProvider.asCoroutineScope(): CoroutineScope

fun CoroutineScope.asCompletable(): Completable

fun Completable.asCoroutineScope(): CoroutineScope
@ZacSweers ZacSweers added this to the 1.4.0 milestone Sep 6, 2019
ZacSweers added a commit that referenced this issue Sep 12, 2019
ZacSweers added a commit that referenced this issue Sep 15, 2019
* Stub coroutines-interop module

* Implement coroutines interop

Resolves #371

* Stub tests

* Remove lint checks

These come transitively

* Implement tests

* Add default to asCoroutineScope instead

* Implement asCoroutineScope with bodies

Super nice high order function with receiver API

* Spotless

* Add in README

* Make RealAutoDisposeCoroutineScope private

* Revert AutoDisposeContext, will move to another PR

* Rename to AutoDisposeCoroutinesInteropTest
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant