From 4ac0dc1bfdf67c55b871c3cddf70c763f09667a7 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Sat, 2 Nov 2013 20:45:22 +0100 Subject: [PATCH] Use HTMLHtmlElement::new in parse_html. --- src/components/script/html/hubbub_html_parser.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/script/html/hubbub_html_parser.rs b/src/components/script/html/hubbub_html_parser.rs index fb74f2be47e..f906a7d21e1 100644 --- a/src/components/script/html/hubbub_html_parser.rs +++ b/src/components/script/html/hubbub_html_parser.rs @@ -333,8 +333,7 @@ pub fn parse_html(cx: *JSContext, } // Build the root node. - let root = @HTMLHtmlElement { htmlelement: HTMLElement::new(HTMLHtmlElementTypeId, ~"html", document) }; - let root = unsafe { Node::as_abstract_node(cx, root) }; + let root = HTMLHtmlElement::new(~"html", document); debug!("created new node"); let mut parser = hubbub::Parser("UTF-8", false); debug!("created parser");