diff options
author | Jack Moffitt <jack@metajack.im> | 2014-11-05 12:33:11 -0700 |
---|---|---|
committer | Glenn Watson <gw@intuitionlibrary.com> | 2014-11-13 11:17:43 +1000 |
commit | d1b433a3b3bab353f320b2f39fa953ce326d2d55 (patch) | |
tree | d7a197abb65827b36c47e6b5c3adcce9071643d3 /components/script/dom/element.rs | |
parent | 26045d7fcbab8851fbefe2851cd904203f8fd8dd (diff) | |
download | servo-d1b433a3b3bab353f320b2f39fa953ce326d2d55.tar.gz servo-d1b433a3b3bab353f320b2f39fa953ce326d2d55.zip |
Rust upgrade to rustc hash b03a2755193cd756583bcf5831cf4545d75ecb8a
Diffstat (limited to 'components/script/dom/element.rs')
-rw-r--r-- | components/script/dom/element.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 9c02a92d68f..9c2031c79cf 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -40,7 +40,7 @@ use style; use servo_util::namespace; use servo_util::str::{DOMString, LengthOrPercentageOrAuto}; -use std::ascii::StrAsciiExt; +use std::ascii::AsciiExt; use std::default::Default; use std::mem; use string_cache::{Atom, Namespace, QualName}; @@ -311,7 +311,7 @@ impl RawLayoutElementHelpers for Element { match length_attribute { WidthLengthAttribute => { if !self.is_htmltablecellelement() { - fail!("I'm not a table cell!") + panic!("I'm not a table cell!") } let this: &HTMLTableCellElement = mem::transmute(self); this.get_width() @@ -326,7 +326,7 @@ impl RawLayoutElementHelpers for Element { match integer_attribute { SizeIntegerAttribute => { if !self.is_htmlinputelement() { - fail!("I'm not a form input!") + panic!("I'm not a form input!") } let this: &HTMLInputElement = mem::transmute(self); Some(this.get_size_for_layout() as i32) @@ -624,7 +624,7 @@ impl<'a> AttributeHandlers for JSRef<'a, Element> { Some(attribute) => { match *attribute.value() { UIntAttrValue(_, value) => value, - _ => fail!("Expected a UIntAttrValue"), + _ => panic!("Expected a UIntAttrValue"), } } None => 0, @@ -1131,7 +1131,7 @@ impl<'a> style::TElement<'a> for JSRef<'a, Element> { let attr = attr.root(); match *attr.value() { AtomAttrValue(ref val) => val.clone(), - _ => fail!("`id` attribute should be AtomAttrValue"), + _ => panic!("`id` attribute should be AtomAttrValue"), } }) } |