-
-
Notifications
You must be signed in to change notification settings - Fork 1.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
fix(es/compat): Fix async generator #8881
Conversation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll wait for reviews because I'm not confident.
swc-bump:
- swc_core
- swc_ecma_compat_es2017
// yield _iterator.return(); | ||
// or | ||
// yield _awaitAsyncGenerator(_iterator.return()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know how this actually work, but judging from babel code
yield _iterator.return() // normal async function
yield _awaitAsyncGenerator(_iterator.return()) // async generator function
Thank you! |
Description:
Related issue: