diff options
Diffstat (limited to 'components/script_layout_interface/lib.rs')
-rw-r--r-- | components/script_layout_interface/lib.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script_layout_interface/lib.rs b/components/script_layout_interface/lib.rs index 4e17570f92d..45c82ee1089 100644 --- a/components/script_layout_interface/lib.rs +++ b/components/script_layout_interface/lib.rs @@ -7,6 +7,7 @@ //! to depend on script. #![deny(unsafe_code)] +#![feature(associated_type_defaults)] extern crate app_units; extern crate atomic_refcell; @@ -24,7 +25,6 @@ extern crate malloc_size_of; extern crate metrics; extern crate msg; extern crate net_traits; -extern crate nonzero; extern crate profile_traits; extern crate range; extern crate script_traits; @@ -45,9 +45,9 @@ use canvas_traits::canvas::CanvasMsg; use ipc_channel::ipc::IpcSender; use libc::c_void; use net_traits::image_cache::PendingImageId; -use nonzero::NonZero; use script_traits::UntrustedNodeAddress; use servo_url::ServoUrl; +use std::ptr::NonNull; use std::sync::atomic::AtomicIsize; use style::data::ElementData; @@ -77,7 +77,7 @@ pub struct OpaqueStyleAndLayoutData { // NB: We really store a `StyleAndLayoutData` here, so be careful! #[ignore_malloc_size_of = "TODO(#6910) Box value that should be counted but \ the type lives in layout"] - pub ptr: NonZero<*mut StyleData>, + pub ptr: NonNull<StyleData>, } #[allow(unsafe_code)] |