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

Correctly delegate .return() in async generator #10422

Merged
merged 4 commits into from Nov 4, 2019

Conversation

nicolo-ribaudo
Copy link
Member

@nicolo-ribaudo nicolo-ribaudo commented Sep 9, 2019

Q                       A
Fixed Issues? Fixes #9905, fixes #9021
Patch: Bug Fix? yes
Major: Breaking Change?
Minor: New Feature?
Tests Added + Pass? Yes
Documentation PR Link
Any Dependency Changes?
License MIT

(rant) Debugging this thing was really painful. When working with async code and generators, node was trying to be helpful by stepping into code in the next tick and it missed a lot of stack frames.

Disclaimer: I'm only 80% sure that this PR is correct.

cc @zenparsing "Git blame" attributes this code to only you. If you have time to review this code it would be really appreciated, since propbably you are one of the only persons which fully understand how it works 😅

@nicolo-ribaudo nicolo-ribaudo added PR: Bug Fix 🐛 A type of pull request used for our changelog categories Spec: Async Generators labels Sep 9, 2019
@babel-bot
Copy link
Collaborator

babel-bot commented Sep 9, 2019

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/11556/

@nicolo-ribaudo
Copy link
Member Author

I think that the tests are failing on node 6 because of a generator bug in that version.

@nicolo-ribaudo
Copy link
Member Author

✔️

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated A closed issue/PR that is archived due to age. Recommended to make a new issue PR: Bug Fix 🐛 A type of pull request used for our changelog categories Spec: Async Generators
Projects
None yet
3 participants