Skip to content

script: Pass &mut JSContext to Constructor and Wrap#42681

Merged
TimvdLippe merged 2 commits intoservo:mainfrom
sagudev:cons
Feb 17, 2026
Merged

script: Pass &mut JSContext to Constructor and Wrap#42681
TimvdLippe merged 2 commits intoservo:mainfrom
sagudev:cons

Conversation

@sagudev
Copy link
Copy Markdown
Member

@sagudev sagudev commented Feb 17, 2026

Testing: Just refactor, but should be covered by WPT
Part of #40600

@sagudev sagudev requested a review from gterzian as a code owner February 17, 2026 11:41
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Feb 17, 2026
@TimvdLippe
Copy link
Copy Markdown
Contributor

@Gae24 do you mind reviewing this one?

Copy link
Copy Markdown
Contributor

@Gae24 Gae24 left a comment

Choose a reason for hiding this comment

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

LGTM

@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Feb 17, 2026
Copy link
Copy Markdown
Contributor

@TimvdLippe TimvdLippe left a comment

Choose a reason for hiding this comment

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

Approving on their behalf

@TimvdLippe TimvdLippe added this pull request to the merge queue Feb 17, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Feb 17, 2026
Merged via the queue into servo:main with commit f623081 Feb 17, 2026
33 checks passed
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Feb 17, 2026
github-merge-queue bot pushed a commit that referenced this pull request Feb 19, 2026
…uctor (#42712)

#42681 did not actually allowed using cx in Constructor, but it did most
heavy lifting. Now we need to pass cx to Constructor call (and skip
CanGc) if cx is requested in Bindings.conf. This PR also test this on
testbindings.

Also we now always use `let cx = &mut cx`, so we can always use just cx
(compiler will automatically deref it into &cx if needed). This is
important because codegen stuff is called from many places to it make
sense/easier to just unify this.

Testing: It compiles

Signed-off-by: sagudev <[email protected]>
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.

4 participants