mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Use Untraceable<T> to hold LayoutDataRef instead of manual Encodable implementation.
This commit is contained in:
parent
54d3a0b280
commit
de0866ab42
3 changed files with 9 additions and 9 deletions
|
@ -646,7 +646,7 @@ impl<'ln> ThreadSafeLayoutNode<'ln> {
|
|||
#[inline(always)]
|
||||
pub fn borrow_layout_data<'a>(&'a self) -> Ref<'a,Option<LayoutDataWrapper>> {
|
||||
unsafe {
|
||||
mem::transmute(self.get().layout_data.borrow())
|
||||
mem::transmute(self.get().layout_data.deref().borrow())
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -654,7 +654,7 @@ impl<'ln> ThreadSafeLayoutNode<'ln> {
|
|||
#[inline(always)]
|
||||
pub fn mutate_layout_data<'a>(&'a self) -> RefMut<'a,Option<LayoutDataWrapper>> {
|
||||
unsafe {
|
||||
mem::transmute(self.get().layout_data.borrow_mut())
|
||||
mem::transmute(self.get().layout_data.deref().borrow_mut())
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue