servo: Merge #5001 - Remove the implementation of ToJSValConvertible for JS<T> (from Ms2ger:JS-to_jsval); r=jdm
authorMs2ger <ms2ger@gmail.com>
Sat, 21 Feb 2015 05:03:51 -0700
changeset 335857 b598aea37b63b2904146fb8883b23ff7c619f651
parent 335856 607852076a8bfca51be07189b09950bfcf3f521b
child 335858 aefc3556cfdeafd4eadb326a49d4943357d1691e
push id86548
push userkwierso@gmail.com
push dateSat, 04 Feb 2017 01:35:21 +0000
treeherdermozilla-inbound@e7b96d015d03 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjdm
servo: Merge #5001 - Remove the implementation of ToJSValConvertible for JS<T> (from Ms2ger:JS-to_jsval); r=jdm It is unused and doesn't serve a purpose. Source-Repo: https://github.com/servo/servo Source-Revision: ea9b0909bdc240a064978accd0c092b8814945d4
servo/components/script/dom/bindings/conversions.rs
--- a/servo/components/script/dom/bindings/conversions.rs
+++ b/servo/components/script/dom/bindings/conversions.rs
@@ -25,17 +25,17 @@
 //! | dictionary types        | `&T`            | *unsupported*  |
 //! | enumeration types       | `T`                              |
 //! | callback function types | `T`                              |
 //! | nullable types          | `Option<T>`                      |
 //! | sequences               | `Vec<T>`                         |
 //! | union types             | `T`                              |
 
 use dom::bindings::codegen::PrototypeList;
-use dom::bindings::js::{JS, JSRef, Root, Unrooted};
+use dom::bindings::js::{JSRef, Root, Unrooted};
 use dom::bindings::str::ByteString;
 use dom::bindings::utils::{Reflectable, Reflector, DOMClass};
 use util::str::DOMString;
 
 use js;
 use js::glue::{RUST_JSID_TO_STRING, RUST_JSID_IS_STRING};
 use js::glue::RUST_JS_NumberValue;
 use js::jsapi::{JSBool, JSContext, JSObject, JSString, jsid};
@@ -517,22 +517,16 @@ impl<T: Reflectable> ToJSValConvertible 
 }
 
 impl<'a, T: Reflectable> ToJSValConvertible for JSRef<'a, T> {
     fn to_jsval(&self, cx: *mut JSContext) -> JSVal {
         self.reflector().to_jsval(cx)
     }
 }
 
-impl<'a, T: Reflectable> ToJSValConvertible for JS<T> {
-    fn to_jsval(&self, cx: *mut JSContext) -> JSVal {
-        self.reflector().to_jsval(cx)
-    }
-}
-
 impl<'a, T: Reflectable> ToJSValConvertible for Unrooted<T> {
     fn to_jsval(&self, cx: *mut JSContext) -> JSVal {
         self.reflector().to_jsval(cx)
     }
 }
 
 impl<T: ToJSValConvertible> ToJSValConvertible for Option<T> {
     fn to_jsval(&self, cx: *mut JSContext) -> JSVal {