Make 'Cell<JS<T>>' traceable.

This commit is contained in:
Tetsuharu OHZEKI 2014-05-28 04:08:13 +09:00
parent da703d6a80
commit bf05e6a9e2

View file

@ -160,3 +160,10 @@ impl<S: Encoder<E>, E> Encodable<S, E> for Traceable<JSVal> {
Ok(())
}
}
/// for a field which contains DOMType
impl<T: Reflectable+Encodable<S, E>, S: Encoder<E>, E> Encodable<S, E> for Cell<JS<T>> {
fn encode(&self, s: &mut S) -> Result<(), E> {
self.get().encode(s)
}
}