From 341e66f66d88b1bfae7d3cc2ec6b870e2beb583c Mon Sep 17 00:00:00 2001 From: Brandon Fairchild Date: Fri, 27 Nov 2015 14:32:57 -0500 Subject: [PATCH] Remove `#[allow(raw_pointer_derive)]` attributes The attributes are unused. Fixes #8699. --- components/script/dom/bindings/callback.rs | 1 - components/script/dom/bindings/reflector.rs | 2 +- components/script/dom/bindings/utils.rs | 3 --- components/script/dom/imagedata.rs | 1 - components/script/dom/node.rs | 2 -- components/script_traits/lib.rs | 1 - ports/cef/window.rs | 1 - 7 files changed, 1 insertion(+), 10 deletions(-) diff --git a/components/script/dom/bindings/callback.rs b/components/script/dom/bindings/callback.rs index 10b19acc6019..01bb7b8815b6 100644 --- a/components/script/dom/bindings/callback.rs +++ b/components/script/dom/bindings/callback.rs @@ -62,7 +62,6 @@ pub struct CallbackInterface { /// A common base class for representing IDL callback function and /// callback interface types. -#[allow(raw_pointer_derive)] #[derive(JSTraceable)] struct CallbackObject { /// The underlying `JSObject`. diff --git a/components/script/dom/bindings/reflector.rs b/components/script/dom/bindings/reflector.rs index d7400a35c991..49e7554944df 100644 --- a/components/script/dom/bindings/reflector.rs +++ b/components/script/dom/bindings/reflector.rs @@ -20,7 +20,7 @@ pub fn reflect_dom_object(obj: Box, } /// A struct to store a reference to the reflector of a DOM object. -#[allow(raw_pointer_derive, unrooted_must_root)] +#[allow(unrooted_must_root)] #[must_root] #[servo_lang = "reflector"] #[derive(HeapSizeOf)] diff --git a/components/script/dom/bindings/utils.rs b/components/script/dom/bindings/utils.rs index 9455cee39572..775df6a45aa1 100644 --- a/components/script/dom/bindings/utils.rs +++ b/components/script/dom/bindings/utils.rs @@ -53,7 +53,6 @@ use util::mem::HeapSizeOf; use util::str::jsstring_to_str; /// Proxy handler for a WindowProxy. -#[allow(raw_pointer_derive)] pub struct WindowProxyHandler(pub *const libc::c_void); impl HeapSizeOf for WindowProxyHandler { @@ -63,7 +62,6 @@ impl HeapSizeOf for WindowProxyHandler { } } -#[allow(raw_pointer_derive)] #[derive(JSTraceable, HeapSizeOf)] /// Static data associated with a global object. pub struct GlobalStaticData { @@ -142,7 +140,6 @@ pub struct NativePropertyHooks { } /// The struct that holds inheritance information for DOM object reflectors. -#[allow(raw_pointer_derive)] #[derive(Copy, Clone)] pub struct DOMClass { /// A list of interfaces that this object implements, in order of decreasing diff --git a/components/script/dom/imagedata.rs b/components/script/dom/imagedata.rs index ffbe0a4b225b..cbc3b489a212 100644 --- a/components/script/dom/imagedata.rs +++ b/components/script/dom/imagedata.rs @@ -17,7 +17,6 @@ use std::slice; use std::vec::Vec; #[dom_struct] -#[allow(raw_pointer_derive)] pub struct ImageData { reflector_: Reflector, width: u32, diff --git a/components/script/dom/node.rs b/components/script/dom/node.rs index 768a2accb1db..941ea5a5a766 100644 --- a/components/script/dom/node.rs +++ b/components/script/dom/node.rs @@ -179,7 +179,6 @@ pub struct SharedLayoutData { } /// Encapsulates the abstract layout data. -#[allow(raw_pointer_derive)] #[derive(HeapSizeOf)] pub struct LayoutData { _shared_data: SharedLayoutData, @@ -2319,7 +2318,6 @@ impl NodeMethods for Node { /// The address of a node known to be valid. These are sent from script to layout, /// and are also used in the HTML parser interface. -#[allow(raw_pointer_derive)] #[derive(Clone, PartialEq, Eq, Copy)] pub struct TrustedNodeAddress(pub *const c_void); diff --git a/components/script_traits/lib.rs b/components/script_traits/lib.rs index 995045e6e17f..685e29c48ec9 100644 --- a/components/script_traits/lib.rs +++ b/components/script_traits/lib.rs @@ -46,7 +46,6 @@ use util::mem::HeapSizeOf; /// The address of a node. Layout sends these back. They must be validated via /// `from_untrusted_node_address` before they can be used, because we do not trust layout. -#[allow(raw_pointer_derive)] #[derive(Copy, Clone, Debug)] pub struct UntrustedNodeAddress(pub *const c_void); unsafe impl Send for UntrustedNodeAddress {} diff --git a/ports/cef/window.rs b/ports/cef/window.rs index faa23db1e828..60d6c460567a 100644 --- a/ports/cef/window.rs +++ b/ports/cef/window.rs @@ -46,7 +46,6 @@ use self::x11::xlib::{XInitThreads,XOpenDisplay}; pub static mut DISPLAY: *mut c_void = 0 as *mut c_void; /// The type of an off-screen window. -#[allow(raw_pointer_derive)] #[derive(Clone)] pub struct Window { cef_browser: RefCell>,