mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
Make 'RefCell<Vec<JS<T>>>' traceable.
This commit is contained in:
parent
bf05e6a9e2
commit
5ae7c4cbb1
1 changed files with 7 additions and 0 deletions
|
@ -167,3 +167,10 @@ impl<T: Reflectable+Encodable<S, E>, S: Encoder<E>, E> Encodable<S, E> for Cell<
|
|||
self.get().encode(s)
|
||||
}
|
||||
}
|
||||
|
||||
/// for a field which contains non-POD type contains DOMType
|
||||
impl<T: Reflectable+Encodable<S, E>, S: Encoder<E>, E> Encodable<S, E> for RefCell<Vec<JS<T>>> {
|
||||
fn encode(&self, s: &mut S) -> Result<(), E> {
|
||||
self.borrow().encode(s)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue