Skip to content
This repository has been archived by the owner on Mar 3, 2020. It is now read-only.

Make boxed generators compatible with futures-cpupool #62

Merged
merged 1 commit into from
Feb 8, 2018

Conversation

raviqqe
Copy link
Contributor

@raviqqe raviqqe commented Feb 7, 2018

Fixes #60.

This change basically adds a new attribute #[async(boxed_send)] which makes boxed generators Send and able to be passed to CpuPool.spawn().

@alexcrichton
Copy link
Owner

Thanks! Could you add a test or two as well?

@raviqqe
Copy link
Contributor Author

raviqqe commented Feb 8, 2018

I added a test of #[async(boxed_send)]. Please review the modified async proc macro as it contains some duplicates around quote_cs!. We should maybe add an xfail test of #[async(box)] with CpuPool.spawn().

Cargo.toml Outdated
@@ -22,6 +22,7 @@ members = ["testcrate"]
futures-await-async-macro = { path = "futures-await-async-macro", version = "0.1" }
futures-await-await-macro = { path = "futures-await-await-macro", version = "0.1" }
futures = "0.1"
futures-cpupool = "0.1"
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could this be moved to [dev-dependencies] as I think it's not necessary for the crate itself?

@raviqqe
Copy link
Contributor Author

raviqqe commented Feb 8, 2018

Moved futures-cpupool to [dev-dependencies].

@alexcrichton alexcrichton merged commit c02cb0a into alexcrichton:master Feb 8, 2018
@alexcrichton
Copy link
Owner

Thanks!

@raviqqe raviqqe deleted the raviqqe branch February 8, 2018 05:42
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants