diff --git a/components/script/Cargo.toml b/components/script/Cargo.toml index 9fda41e036f..fd84383c346 100644 --- a/components/script/Cargo.toml +++ b/components/script/Cargo.toml @@ -78,7 +78,7 @@ hyper = { version = "0.8", features = [ "serde-serialization" ] } image = "0.9" libc = "0.2" log = "0.3.5" -num = "0.1.24" +num-traits = "0.1.32" offscreen_gl_context = "0.1.2" rand = "0.3" phf = "0.7.13" diff --git a/components/script/dom/bindings/conversions.rs b/components/script/dom/bindings/conversions.rs index 060d3d598ca..baeb0a1f92b 100644 --- a/components/script/dom/bindings/conversions.rs +++ b/components/script/dom/bindings/conversions.rs @@ -53,7 +53,7 @@ use js::jsapi::{Type}; use js::jsval::{ObjectValue, StringValue}; use js::rust::ToString; use libc; -use num::Float; +use num_traits::Float; use std::{ptr, mem, slice}; pub use util::non_geckolib::{StringificationBehavior, jsstring_to_str}; use util::str::DOMString; diff --git a/components/script/dom/bindings/num.rs b/components/script/dom/bindings/num.rs index 972f90389d1..fde24d08421 100644 --- a/components/script/dom/bindings/num.rs +++ b/components/script/dom/bindings/num.rs @@ -4,7 +4,7 @@ //! The `Finite` struct. -use num::Float; +use num_traits::Float; use std::ops::Deref; /// Encapsulates the IDL restricted float type. diff --git a/components/script/dom/blob.rs b/components/script/dom/blob.rs index 9c23b8f6da0..de7a7b8c35a 100644 --- a/components/script/dom/blob.rs +++ b/components/script/dom/blob.rs @@ -12,7 +12,7 @@ use dom::bindings::reflector::{Reflectable, Reflector, reflect_dom_object}; use dom::bindings::trace::JSTraceable; use encoding::all::UTF_8; use encoding::types::{EncoderTrap, Encoding}; -use num::ToPrimitive; +use num_traits::ToPrimitive; use std::ascii::AsciiExt; use std::borrow::ToOwned; use std::cell::Cell; diff --git a/components/script/dom/canvasrenderingcontext2d.rs b/components/script/dom/canvasrenderingcontext2d.rs index 492b98f0edf..a0c4ee9d021 100644 --- a/components/script/dom/canvasrenderingcontext2d.rs +++ b/components/script/dom/canvasrenderingcontext2d.rs @@ -39,7 +39,7 @@ use euclid::size::Size2D; use ipc_channel::ipc::{self, IpcSender}; use net_traits::image::base::PixelFormat; use net_traits::image_cache_thread::ImageResponse; -use num::{Float, ToPrimitive}; +use num_traits::{Float, ToPrimitive}; use script_traits::ScriptMsg as ConstellationMsg; use std::cell::Cell; use std::str::FromStr; diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index d87e80b7acc..12eab0cf4e2 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -93,7 +93,7 @@ use net_traits::ControlMsg::{GetCookiesForUrl, SetCookiesForUrl}; use net_traits::CookieSource::NonHTTP; use net_traits::response::HttpsState; use net_traits::{AsyncResponseTarget, PendingAsyncLoad}; -use num::ToPrimitive; +use num_traits::ToPrimitive; use origin::Origin; use script_runtime::ScriptChan; use script_thread::{MainThreadScriptChan, MainThreadScriptMsg, Runnable}; diff --git a/components/script/dom/htmlanchorelement.rs b/components/script/dom/htmlanchorelement.rs index 16f47315b76..c66617bfb3a 100644 --- a/components/script/dom/htmlanchorelement.rs +++ b/components/script/dom/htmlanchorelement.rs @@ -25,7 +25,7 @@ use dom::mouseevent::MouseEvent; use dom::node::{Node, document_from_node, window_from_node}; use dom::urlhelper::UrlHelper; use dom::virtualmethods::VirtualMethods; -use num::ToPrimitive; +use num_traits::ToPrimitive; use std::default::Default; use string_cache::Atom; use url::{Url, UrlParser}; diff --git a/components/script/dom/window.rs b/components/script/dom/window.rs index 8a3affefe06..9a8d97c23ef 100644 --- a/components/script/dom/window.rs +++ b/components/script/dom/window.rs @@ -48,7 +48,7 @@ use msg::webdriver_msg::{WebDriverJSError, WebDriverJSResult}; use net_traits::ResourceThread; use net_traits::image_cache_thread::{ImageCacheChan, ImageCacheThread}; use net_traits::storage_thread::{StorageThread, StorageType}; -use num::traits::ToPrimitive; +use num_traits::ToPrimitive; use page::Page; use profile_traits::mem; use reporter::CSSErrorReporter; diff --git a/components/script/lib.rs b/components/script/lib.rs index e525a62b70d..2827238dcef 100644 --- a/components/script/lib.rs +++ b/components/script/lib.rs @@ -53,7 +53,7 @@ extern crate libc; extern crate log; extern crate msg; extern crate net_traits; -extern crate num; +extern crate num_traits; extern crate offscreen_gl_context; extern crate phf; #[macro_use] diff --git a/components/script/timers.rs b/components/script/timers.rs index 7816106c9d7..473b2fc030c 100644 --- a/components/script/timers.rs +++ b/components/script/timers.rs @@ -15,7 +15,7 @@ use heapsize::HeapSizeOf; use ipc_channel::ipc::IpcSender; use js::jsapi::{HandleValue, Heap, RootedValue}; use js::jsval::{JSVal, UndefinedValue}; -use num::traits::Saturating; +use num_traits::Saturating; use script_traits::{MsDuration, precise_time_ms}; use script_traits::{TimerEvent, TimerEventId, TimerEventRequest, TimerSource}; use std::cell::Cell; diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index 33a3270c05c..2720e51b000 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -1773,7 +1773,7 @@ dependencies = [ "log 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)", "msg 0.0.1", "net_traits 0.0.1", - "num 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)", + "num-traits 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)", "offscreen_gl_context 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "phf 0.7.13 (registry+https://github.com/rust-lang/crates.io-index)", "phf_macros 0.7.13 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/cef/Cargo.lock b/ports/cef/Cargo.lock index 309ef9907b3..9a924ee6803 100644 --- a/ports/cef/Cargo.lock +++ b/ports/cef/Cargo.lock @@ -1649,7 +1649,7 @@ dependencies = [ "log 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)", "msg 0.0.1", "net_traits 0.0.1", - "num 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)", + "num-traits 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)", "offscreen_gl_context 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "phf 0.7.13 (registry+https://github.com/rust-lang/crates.io-index)", "phf_macros 0.7.13 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/gonk/Cargo.lock b/ports/gonk/Cargo.lock index 79ed831c57e..6a76a679eb0 100644 --- a/ports/gonk/Cargo.lock +++ b/ports/gonk/Cargo.lock @@ -1631,7 +1631,7 @@ dependencies = [ "log 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)", "msg 0.0.1", "net_traits 0.0.1", - "num 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)", + "num-traits 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)", "offscreen_gl_context 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "phf 0.7.13 (registry+https://github.com/rust-lang/crates.io-index)", "phf_macros 0.7.13 (registry+https://github.com/rust-lang/crates.io-index)",