diff options
author | Manish Goregaokar <manishsmail@gmail.com> | 2014-09-17 01:00:59 +0530 |
---|---|---|
committer | Manish Goregaokar <manishsmail@gmail.com> | 2014-09-17 01:02:44 +0530 |
commit | f5087e149004e0080a61a2a31d76a5c52ee357e1 (patch) | |
tree | 6e9507a3e4e8ce3c84ab603673d3eead9ae0d1b0 /components/script/dom/htmlelement.rs | |
parent | 30014c3919f5ad30d491074dafbfdaad0fb0de92 (diff) | |
download | servo-f5087e149004e0080a61a2a31d76a5c52ee357e1.tar.gz servo-f5087e149004e0080a61a2a31d76a5c52ee357e1.zip |
Use #[must_root] for HTMLElements
Diffstat (limited to 'components/script/dom/htmlelement.rs')
-rw-r--r-- | components/script/dom/htmlelement.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/components/script/dom/htmlelement.rs b/components/script/dom/htmlelement.rs index 08ab88463c4..c9c5b5d4ba8 100644 --- a/components/script/dom/htmlelement.rs +++ b/components/script/dom/htmlelement.rs @@ -22,7 +22,7 @@ use servo_util::namespace; use servo_util::str::DOMString; #[deriving(Encodable)] -#[allow(unrooted_must_root)] +#[must_root] pub struct HTMLElement { pub element: Element } @@ -44,6 +44,7 @@ impl HTMLElement { } } + #[allow(unrooted_must_root)] pub fn new(localName: DOMString, document: &JSRef<Document>) -> Temporary<HTMLElement> { let element = HTMLElement::new_inherited(HTMLElementTypeId, localName, document); Node::reflect_node(box element, document, HTMLElementBinding::Wrap) |