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

await macro is not in libcore. #56767

Open
james-darkfox opened this Issue Dec 13, 2018 · 4 comments

Comments

Projects
None yet
4 participants
@james-darkfox
Copy link
Contributor

james-darkfox commented Dec 13, 2018

The await!() macro is defined in std but not in core, is there any reason for this?

@bjorn3

This comment has been minimized.

Copy link
Contributor

bjorn3 commented Dec 13, 2018

It uses thread local storage, which isnt available outside libstd.

@james-darkfox

This comment has been minimized.

Copy link
Contributor Author

james-darkfox commented Dec 13, 2018

@Nemo157

This comment has been minimized.

Copy link
Contributor

Nemo157 commented Dec 13, 2018

It's intended to be moved to core at some point (there's a few ways to reimplement it, embrio-async's implementation is one but has some relatively spread out safety guarantees, adding the ability for generators to take resume arguments is another that I think would avoid needing any unsafe code at all).

I thought this was already noted on the tracking issue (#50547), but looking at it again it doesn't appear so, adding this issue to the unresolved questions would probably be useful.

@Nemo157 Nemo157 referenced this issue Dec 13, 2018

Open

Tracking issue for async/await (RFC 2394) #50547

1 of 11 tasks complete
@james-darkfox

This comment has been minimized.

Copy link
Contributor Author

james-darkfox commented Dec 13, 2018

Thanks @Nemo157

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment