aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/script/dom/domimplementation.rs
diff options
context:
space:
mode:
authorJosh Matthews <josh@joshmatthews.net>2014-03-14 14:46:30 -0400
committerLars Bergstrom <lars@lars.com>2014-03-18 09:31:22 -0500
commit64c0de9fe7dc5555821ca5cb4c13aa2418e91b94 (patch)
treef8bee1d1d3b38572a3e2519542d5548e251e802d /src/components/script/dom/domimplementation.rs
parentf279abbf9f894641f592fee7f70fa0e29d955dad (diff)
downloadservo-64c0de9fe7dc5555821ca5cb4c13aa2418e91b94.tar.gz
servo-64c0de9fe7dc5555821ca5cb4c13aa2418e91b94.zip
Warning police.
Diffstat (limited to 'src/components/script/dom/domimplementation.rs')
-rw-r--r--src/components/script/dom/domimplementation.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/components/script/dom/domimplementation.rs b/src/components/script/dom/domimplementation.rs
index 5a11d0119d4..71f63f52066 100644
--- a/src/components/script/dom/domimplementation.rs
+++ b/src/components/script/dom/domimplementation.rs
@@ -72,18 +72,18 @@ impl DOMImplementation {
{
// Step 3.
let doc_type = DocumentType::new(~"html", None, None, &doc);
- doc_node.AppendChild(&mut NodeCast::from(&doc_type));
+ assert!(doc_node.AppendChild(&mut NodeCast::from(&doc_type)).is_ok());
}
{
// Step 4.
let mut doc_html = NodeCast::from(&HTMLHtmlElement::new(~"html", &doc));
- doc_node.AppendChild(&mut doc_html);
+ assert!(doc_node.AppendChild(&mut doc_html).is_ok());
{
// Step 5.
let mut doc_head = NodeCast::from(&HTMLHeadElement::new(~"head", &doc));
- doc_html.AppendChild(&mut doc_head);
+ assert!(doc_html.AppendChild(&mut doc_head).is_ok());
// Step 6.
match title {
@@ -91,18 +91,18 @@ impl DOMImplementation {
Some(title_str) => {
// Step 6.1.
let mut doc_title = NodeCast::from(&HTMLTitleElement::new(~"title", &doc));
- doc_head.AppendChild(&mut doc_title);
+ assert!(doc_head.AppendChild(&mut doc_title).is_ok());
// Step 6.2.
let title_text = Text::new(title_str, &doc);
- doc_title.AppendChild(&mut NodeCast::from(&title_text));
+ assert!(doc_title.AppendChild(&mut NodeCast::from(&title_text)).is_ok());
}
}
}
// Step 7.
let doc_body = HTMLBodyElement::new(~"body", &doc);
- doc_html.AppendChild(&mut NodeCast::from(&doc_body));
+ assert!(doc_html.AppendChild(&mut NodeCast::from(&doc_body)).is_ok());
}
// Step 8.