-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Add async/await sugar on top of generators/yield #3747
Comments
I don't think we're going to support es7 features before any environment supports it. Wontfix for now. |
What do you mean by environment? |
Browsers, node, etc. |
I see, what is the motivation for doing this? |
this(Browser and below node 0.11.2) can be supported via regenerator. So we need async/await now. |
@jashkenas expressed his intent here: #3073 (comment) |
@vendethiel CS has always implemented features that were not, and still are not in JS. That is the whole point of CS. How would this be any different? |
No, that's not the case. Features added were not "as ES6" (because those weren't pinned at the time). |
I am not talking about ES6 features speifically. In general CS has added sugar over JS. Is the only reason to not implement async/await, the fact that a similar feature is in the proposal phase fo ES7? |
@GabrielRatener If you'd like to see a more serious discussion of this idea happen, please open a pull request with a sketch of how you'd propose to implement |
@jashkenas Just opened PR #3757, full proposal, tested and ready to be tried. |
Should CS support async/await sugar on top of generators and yield?
This can be done with little overhead, and seems like sensible sugar to add to the language, since generators and yield are used largely to pause function execution and resolve promises.
The text was updated successfully, but these errors were encountered: