Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Simplify Array.fromAsync lazy loading #982

Merged
merged 2 commits into from
Mar 17, 2025

Conversation

bnoordhuis
Copy link
Contributor

Store it as classic JS instead of an ES module that we need to pull
apart first.

Added benefit is that it shrinks the serialized representation by 5%.


First commit is #978, necessary for the -C flag to qjsc.

Add -C as the complementary to the -m flag to qjsc that compiles
the input as an ES module.

Add -C as a shorthand alias for --script to qjs and harmonize the
qjs and qjsc help messages.

Capital C because -c is already taken.
Store it as classic JS instead of an ES module that we need to pull
apart first.

Added benefit is that it shrinks the serialized representation by 5%.
@saghul
Copy link
Contributor

saghul commented Mar 17, 2025

Unrelated: shall we move this one header file to the root, since it simplifies the "copy a bunch of c and h files" build method?

@bnoordhuis
Copy link
Contributor Author

Will the make codegen CI step still catch it when it's out of sync?

@bnoordhuis bnoordhuis merged commit 97e6ef9 into quickjs-ng:master Mar 17, 2025
128 checks passed
@bnoordhuis bnoordhuis deleted the array-fromasync-classic branch March 17, 2025 10:32
@bnoordhuis
Copy link
Contributor Author

Will the make codegen CI step still catch it when it's out of sync?

Replying to myself: yes, it will.

I don't strongly object but I like about the current setup that gen/ clearly indicates it's auto-generated.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants