diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2015-11-21 06:21:02 +0530 |
---|---|---|
committer | bors-servo <lbergstrom+bors@mozilla.com> | 2015-11-21 06:21:02 +0530 |
commit | 18ee6bc30a90855beb7574a5e7627b436e12c193 (patch) | |
tree | 4d08d460c02ab291399fa45c5316d125bdd5a86a | |
parent | 8b6bfb615a8a04177c321c4940f79f090b0a7971 (diff) | |
parent | 964c8355b7135ac6ad939dd7c69a40bfddc6d693 (diff) | |
download | servo-18ee6bc30a90855beb7574a5e7627b436e12c193.tar.gz servo-18ee6bc30a90855beb7574a5e7627b436e12c193.zip |
Auto merge of #8617 - Ms2ger:unused-as, r=jdm
Remove an unused trait.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8617)
<!-- Reviewable:end -->
-rw-r--r-- | components/script/dom/bindings/conversions.rs | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/components/script/dom/bindings/conversions.rs b/components/script/dom/bindings/conversions.rs index 4afbe9aa29b..b887fd27d76 100644 --- a/components/script/dom/bindings/conversions.rs +++ b/components/script/dom/bindings/conversions.rs @@ -56,48 +56,6 @@ use std::{ptr, slice}; use util::str::DOMString; pub use util::str::{StringificationBehavior, jsstring_to_str}; - -trait As<O>: Copy { - fn cast(self) -> O; -} - -macro_rules! impl_as { - ($I:ty, $O:ty) => ( - impl As<$O> for $I { - fn cast(self) -> $O { - self as $O - } - } - ) -} - -impl_as!(f64, u8); -impl_as!(f64, u16); -impl_as!(f64, u32); -impl_as!(f64, u64); -impl_as!(f64, i8); -impl_as!(f64, i16); -impl_as!(f64, i32); -impl_as!(f64, i64); - -impl_as!(u8, f64); -impl_as!(u16, f64); -impl_as!(u32, f64); -impl_as!(u64, f64); -impl_as!(i8, f64); -impl_as!(i16, f64); -impl_as!(i32, f64); -impl_as!(i64, f64); - -impl_as!(i32, i8); -impl_as!(i32, u8); -impl_as!(i32, i16); -impl_as!(u16, u16); -impl_as!(i32, i32); -impl_as!(u32, u32); -impl_as!(i64, i64); -impl_as!(u64, u64); - /// A trait to check whether a given `JSObject` implements an IDL interface. pub trait IDLInterface { /// Returns whether the given DOM class derives that interface. |