Thanks to visit codestin.com
Credit goes to github.com

Skip to content

PoC: Support for function*/yield. #5082

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

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

sjrd
Copy link
Member

@sjrd sjrd commented Nov 26, 2024

Would fix #5079.

  • Only only works on JS; not on Wasm.
  • yield_* should work (on JS) but is untested.
  • async function* has theoretical support in the linker, but no support in the compiler backend for now.

Try helloworld2_12/run. On JS you can uncomment the code that uses the generator. Left commented out in the PR so that there's a chance the CI can get green.

@sjrd sjrd force-pushed the async-and-generators branch 2 times, most recently from c8a4b12 to 1a985b7 Compare December 1, 2024 12:01
@sjrd sjrd force-pushed the async-and-generators branch from 1a985b7 to 6e43d81 Compare February 6, 2025 16:42
@sjrd sjrd force-pushed the async-and-generators branch from 6e43d81 to a7954fa Compare April 7, 2025 15:51
@sjrd sjrd changed the title PoC: Support for async/await and function*/yield. PoC: Support for function*/yield. Apr 7, 2025
@sjrd sjrd force-pushed the async-and-generators branch from a7954fa to 29cf256 Compare April 8, 2025 16:03
sjrd added 2 commits April 22, 2025 10:08
As well as the IR version to 1.20-SNAPSHOT.
Would fix scala-js#5079.

* Only works on JS; not on Wasm.
* `yield_*` should work (on JS) but is untested.
* `async function*` has theoretical support in the linker, but no
  support in the compiler backend for now.
@sjrd sjrd force-pushed the async-and-generators branch from 29cf256 to 804099c Compare April 22, 2025 08:24
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

Successfully merging this pull request may close these issues.

Support Generators, function*, and yield
1 participant