mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
Remove the pointer to the Rust object in Root.
It is already stored inside the jsref field.
This commit is contained in:
parent
362feaa4a9
commit
2b06bbdb2f
1 changed files with 0 additions and 3 deletions
|
@ -388,8 +388,6 @@ pub struct Root<'a, 'b, T> {
|
||||||
root_list: &'a RootCollection,
|
root_list: &'a RootCollection,
|
||||||
/// Reference to rooted value that must not outlive this container
|
/// Reference to rooted value that must not outlive this container
|
||||||
jsref: JSRef<'b, T>,
|
jsref: JSRef<'b, T>,
|
||||||
/// Pointer to underlying Rust data
|
|
||||||
ptr: *T,
|
|
||||||
/// On-stack JS pointer to assuage conservative stack scanner
|
/// On-stack JS pointer to assuage conservative stack scanner
|
||||||
js_ptr: *mut JSObject,
|
js_ptr: *mut JSObject,
|
||||||
}
|
}
|
||||||
|
@ -405,7 +403,6 @@ impl<'a, 'b, T: Reflectable> Root<'a, 'b, T> {
|
||||||
ptr: unrooted.ptr.clone(),
|
ptr: unrooted.ptr.clone(),
|
||||||
chain: ContravariantLifetime,
|
chain: ContravariantLifetime,
|
||||||
},
|
},
|
||||||
ptr: unrooted.ptr.clone(),
|
|
||||||
js_ptr: unrooted.reflector().get_jsobject(),
|
js_ptr: unrooted.reflector().get_jsobject(),
|
||||||
};
|
};
|
||||||
roots.root(&root);
|
roots.root(&root);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue