Skip to content

script_bindings: pass JSContext to callbacks constructors - #46084

Merged
Gae24 merged 2 commits into
servo:mainfrom
Gae24:callback-cx
Jun 29, 2026
Merged

script_bindings: pass JSContext to callbacks constructors#46084
Gae24 merged 2 commits into
servo:mainfrom
Gae24:callback-cx

Conversation

@Gae24

@Gae24 Gae24 commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Testing: It compiles
Part of #40600

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
@Gae24
Gae24 requested a review from gterzian as a code owner June 29, 2026 10:45
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Jun 29, 2026

@sagudev sagudev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Otherwise LGTM

Comment thread components/script/dom/bindings/function.rs
def getConstructors(self) -> list[ClassConstructor]:
return [ClassConstructor(
[Argument("SafeJSContext", "aCx"), Argument("*mut JSObject", "aCallback")],
[Argument("&JSContext", "cx"), Argument("*mut JSObject", "aCallback")],

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

praise: no mut \o/

@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Jun 29, 2026
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Jun 29, 2026
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
@Gae24
Gae24 added this pull request to the merge queue Jun 29, 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 Jun 29, 2026
Merged via the queue into servo:main with commit a63a548 Jun 29, 2026
31 checks passed
@Gae24
Gae24 deleted the callback-cx branch June 29, 2026 14:44
@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 Jun 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-awaiting-review There is new code that needs to be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants