Change Namespace::to_str() to not allocate and return a reference.

This commit is contained in:
Simon Sapin 2013-12-09 15:10:09 +00:00
parent 28575c20bf
commit 61c7f2f220
5 changed files with 23 additions and 23 deletions

View file

@ -75,7 +75,7 @@ impl Attr {
}
pub fn GetNamespaceURI(&self) -> Option<DOMString> {
self.namespace.to_str()
self.namespace.to_str().map(|s| s.to_owned())
}
pub fn GetPrefix(&self) -> Option<DOMString> {