From 63314208c0967c7f23b1387742f26d2f409a05f2 Mon Sep 17 00:00:00 2001 From: Cameron Zwarich Date: Tue, 30 Sep 2014 20:54:19 -0700 Subject: [PATCH] Add Copy bounds to TNode / TElement --- components/style/node.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/style/node.rs b/components/style/node.rs index 7720f37c30a..cb267a71966 100644 --- a/components/style/node.rs +++ b/components/style/node.rs @@ -9,7 +9,7 @@ use selectors::AttrSelector; use string_cache::{Atom, Namespace}; -pub trait TNode<'a, E: TElement<'a>> : Clone { +pub trait TNode<'a, E: TElement<'a>> : Clone + Copy { fn parent_node(&self) -> Option; fn first_child(&self) -> Option; fn prev_sibling(&self) -> Option; @@ -21,7 +21,7 @@ pub trait TNode<'a, E: TElement<'a>> : Clone { fn is_html_element_in_html_document(&self) -> bool; } -pub trait TElement<'a> { +pub trait TElement<'a> : Copy { fn get_attr(&self, namespace: &Namespace, attr: &str) -> Option<&'a str>; fn get_link(&self) -> Option<&'a str>; fn get_local_name(&self) -> &'a Atom;