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

Replace js_mode with is_strict_mode bit field #590

Merged
merged 1 commit into from
Oct 10, 2024

Conversation

bnoordhuis
Copy link
Contributor

Shrinks some structures by one or more bytes and is easier to read.

Shrinks some structures by one or more bytes and is easier to read.
@@ -33881,7 +33870,7 @@ static int JS_WriteFunctionTag(BCWriterState *s, JSValue obj)
bc_set_flags(&flags, &idx, s->allow_debug, 1);
assert(idx <= 16);
bc_put_u16(s, flags);
bc_put_u8(s, b->js_mode);
bc_put_u8(s, b->is_strict_mode);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: this was already writing either 1 or 0, so this is backwards compatible

@bnoordhuis bnoordhuis merged commit e145244 into quickjs-ng:master Oct 10, 2024
52 checks passed
@bnoordhuis bnoordhuis deleted the strictmodebitfield branch October 10, 2024 17:31
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.

2 participants