Remove unnecessary mutability.

This commit is contained in:
Ms2ger 2013-10-06 09:15:38 +02:00
parent 17796725f4
commit 179582d939
3 changed files with 3 additions and 3 deletions

View file

@ -117,7 +117,7 @@ impl Document {
pub fn Constructor(owner: @mut Window) -> Fallible<AbstractDocument> { pub fn Constructor(owner: @mut Window) -> Fallible<AbstractDocument> {
let cx = owner.page.js_info.get_ref().js_compartment.cx.ptr; let cx = owner.page.js_info.get_ref().js_compartment.cx.ptr;
let mut document = AbstractDocument::as_abstract(cx, @mut Document::new(None, XML)); let document = AbstractDocument::as_abstract(cx, @mut Document::new(None, XML));
let root = @HTMLHtmlElement { let root = @HTMLHtmlElement {
htmlelement: HTMLElement::new(HTMLHtmlElementTypeId, ~"html") htmlelement: HTMLElement::new(HTMLHtmlElementTypeId, ~"html")

View file

@ -42,7 +42,7 @@ impl DOMParser {
ty: DOMParserBinding::SupportedType) ty: DOMParserBinding::SupportedType)
-> Fallible<AbstractDocument> { -> Fallible<AbstractDocument> {
let cx = (*self.owner.page).js_info.get_ref().js_compartment.cx.ptr; let cx = (*self.owner.page).js_info.get_ref().js_compartment.cx.ptr;
let mut document = match ty { let document = match ty {
Text_html => { Text_html => {
HTMLDocument::new(None) HTMLDocument::new(None)
} }

View file

@ -722,7 +722,7 @@ impl ScriptTask {
page.next_subpage_id.clone(), page.next_subpage_id.clone(),
self.constellation_chan.clone()); self.constellation_chan.clone());
let mut document = HTMLDocument::new(Some(window)); let document = HTMLDocument::new(Some(window));
let HtmlParserResult {root, discovery_port, url: final_url} = html_parsing_result; let HtmlParserResult {root, discovery_port, url: final_url} = html_parsing_result;
document.set_root(root); document.set_root(root);