aboutsummaryrefslogtreecommitdiffstats
path: root/components/script
diff options
context:
space:
mode:
authorAnthony Ramine <n.oxyde@gmail.com>2016-06-06 14:47:16 +0200
committerAnthony Ramine <n.oxyde@gmail.com>2016-06-08 14:03:57 +0200
commitb7f5e8d0135a2fbecc749206a27f84dd10dc2e84 (patch)
tree35ef9c588bcaec229ba5a9491b8db57f2e96c563 /components/script
parenta80767993b6b2b885dfac9666f16fb1e1649ac99 (diff)
downloadservo-b7f5e8d0135a2fbecc749206a27f84dd10dc2e84.tar.gz
servo-b7f5e8d0135a2fbecc749206a27f84dd10dc2e84.zip
Update Rust to 1.11.0-nightly (ec872dc8a 2016-06-07)
Diffstat (limited to 'components/script')
-rw-r--r--components/script/dom/document.rs2
-rw-r--r--components/script/dom/node.rs6
-rw-r--r--components/script/lib.rs1
3 files changed, 4 insertions, 5 deletions
diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs
index 2a7466dc2eb..6e4b4b030e8 100644
--- a/components/script/dom/document.rs
+++ b/components/script/dom/document.rs
@@ -2675,7 +2675,7 @@ impl DocumentMethods for Document {
.filter(|node| filter_by_name(&name, node.r()))
.peekable();
if let Some(first) = elements.next() {
- if elements.is_empty() {
+ if elements.peek().is_none() {
*found = true;
// TODO: Step 2.
// Step 3.
diff --git a/components/script/dom/node.rs b/components/script/dom/node.rs
index d3e6a955284..3032abe0685 100644
--- a/components/script/dom/node.rs
+++ b/components/script/dom/node.rs
@@ -1452,7 +1452,7 @@ impl Node {
0 => (),
// Step 6.1.2
1 => {
- if !parent.child_elements().is_empty() {
+ if !parent.child_elements().peek().is_none() {
return Err(Error::HierarchyRequest);
}
if let Some(child) = child {
@@ -1468,7 +1468,7 @@ impl Node {
},
// Step 6.2
NodeTypeId::Element(_) => {
- if !parent.child_elements().is_empty() {
+ if !parent.child_elements().peek().is_none() {
return Err(Error::HierarchyRequest);
}
if let Some(ref child) = child {
@@ -1495,7 +1495,7 @@ impl Node {
}
},
None => {
- if !parent.child_elements().is_empty() {
+ if !parent.child_elements().peek().is_none() {
return Err(Error::HierarchyRequest);
}
},
diff --git a/components/script/lib.rs b/components/script/lib.rs
index f932c4d0291..c2aa794719f 100644
--- a/components/script/lib.rs
+++ b/components/script/lib.rs
@@ -15,7 +15,6 @@
#![feature(nonzero)]
#![feature(on_unimplemented)]
#![feature(optin_builtin_traits)]
-#![feature(peekable_is_empty)]
#![feature(plugin)]
#![feature(slice_patterns)]
#![feature(stmt_expr_attributes)]