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

Reconsider Context::executor returning Option #944

Closed
carllerche opened this issue Apr 5, 2018 · 2 comments
Closed

Reconsider Context::executor returning Option #944

carllerche opened this issue Apr 5, 2018 · 2 comments

Comments

@carllerche
Copy link
Member

It seems that Context::executor was changed to return Option because in no_std Executor is not available.

However, the executor fn is not included when no_std is enabled. Given that Context::executor is present so that all callers can assume that an executor is present, would it be better for it not to return an Option?

Maybe if std is present, initializing a Context w/o a can panic?

@aturon
Copy link
Member

aturon commented Apr 6, 2018

Yeah, I think this was a design mistake. I now have a design in mind that is no_std compatible and allows everyone to use executors, but I want to punt it to 0.3 (so we can go ahead and get 0.2 out the door). RFC coming soon.

@carllerche
Copy link
Member Author

carllerche commented Apr 6, 2018

What is the timeline to 0.3?

Is the plan that 0.3 will include a breaking change for futures-core?

cramertj added a commit to cramertj/futures-rs that referenced this issue Apr 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants