mirror of
https://github.com/servo/servo
synced 2026-04-26 01:25:32 +02:00
script: Pass &mut JSContext to reflect_node_with_proto (#43952)
A lot (and I mean, really a lot) depends on these constructors. Therefore, this is the one spaghetti ball that I could extract and convert all `can_gc` to `cx`. There are some new introductions of `temp_cx` in the callbacks of the servo parser, but we already had some in other callbacks. Part of #40600 Testing: It compiles Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
This commit is contained in:
committed by
GitHub
parent
621f6b0cf7
commit
a1c8896eda
@@ -692,19 +692,19 @@ impl HTMLIFrameElement {
|
||||
}
|
||||
|
||||
pub(crate) fn new(
|
||||
cx: &mut js::context::JSContext,
|
||||
local_name: LocalName,
|
||||
prefix: Option<Prefix>,
|
||||
document: &Document,
|
||||
proto: Option<HandleObject>,
|
||||
can_gc: CanGc,
|
||||
) -> DomRoot<HTMLIFrameElement> {
|
||||
Node::reflect_node_with_proto(
|
||||
cx,
|
||||
Box::new(HTMLIFrameElement::new_inherited(
|
||||
local_name, prefix, document,
|
||||
)),
|
||||
document,
|
||||
proto,
|
||||
can_gc,
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user