Skip to content

[test] Test manual prototype configuration#77

Merged
tlively merged 1 commit intomainfrom
js-api-basic-test
Nov 4, 2025
Merged

[test] Test manual prototype configuration#77
tlively merged 1 commit intomainfrom
js-api-basic-test

Conversation

@tlively
Copy link
Member

@tlively tlively commented Nov 3, 2025

Update wasm-module-builder.js with the new custom descriptors
functionality that has been added to the V8 version of the file, then
use it to test that installing prototypes on descriptors works as
intended.

Update wasm-module-builder.js with the new custom descriptors
functionality that has been added to the V8 version of the file, then
use it to test that installing prototypes on descriptors works as
intended.
@tlively
Copy link
Member Author

tlively commented Nov 3, 2025

@rmahdav PTAL as well!

Comment on lines +853 to +856
is_final = fields.is_final ?? fields.final ?? false;
supertype_idx = MustBeNumber(
fields.supertype_idx ?? fields.supertype ?? kNoSuperType,
"supertype");
Copy link
Member

Choose a reason for hiding this comment

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

I don't understand the duplication here. Why are there two ways to pass these arguments?

Copy link
Member Author

Choose a reason for hiding this comment

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

Using an option bag is convenient for building types with lots of things going on such as descriptors, describees, etc. The non-option-bag interface is kept for compatibility with existing tests, but doesn't support new features.

@tlively tlively merged commit 7ea2de0 into main Nov 4, 2025
1 check passed
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