diff options
author | Corey Farwell <coreyf@rwell.org> | 2015-03-29 13:33:02 -0400 |
---|---|---|
committer | Corey Farwell <coreyf@rwell.org> | 2015-03-29 14:42:19 -0400 |
commit | d838fcce30d56e02bd22c4bcfca04d39bf4fc38e (patch) | |
tree | 3a906417b1c164990bc308ff790913b9c7c08740 /components/script/dom/document.rs | |
parent | b8ea10bfe3386357b68e5564332cf8ac9d5377bb (diff) | |
download | servo-d838fcce30d56e02bd22c4bcfca04d39bf4fc38e.tar.gz servo-d838fcce30d56e02bd22c4bcfca04d39bf4fc38e.zip |
Remove some unnecessary uses of `as_slice`
For the majority of these cases, `as_slice` can be removed due to
`Deref`. In particular, `Deref` for:
* `String` -> `str`
* `Atom` -> `str`
The latter of those two requires, a bump of the locked `string-cache`
library
Diffstat (limited to 'components/script/dom/document.rs')
-rw-r--r-- | components/script/dom/document.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index 8ceb6ace1f3..debd6c0831a 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -323,7 +323,7 @@ impl<'a> DocumentHelpers<'a> for JSRef<'a, Document> { let node: JSRef<Node> = NodeCast::from_ref(element); node.is_in_doc() }); - assert!(!id.as_slice().is_empty()); + assert!(!id.is_empty()); let mut idmap = self.idmap.borrow_mut(); |