servo: Merge #9380 - Update cssparser (from servo:cssparserup); r=SimonSapin
authorSimon Sapin <simon.sapin@exyr.org>
Thu, 21 Jan 2016 22:16:21 +0500
changeset 367003 9dc742835b57cb0d99cf8d0966bedcaa3e9c28c4
parent 367002 3bf89fb5373005d67f42fe0751e3c01d225cd83a
child 367004 1405b608998f01e5225bdcbe28bd64e8c20f9d69
push id10863
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 23:02:23 +0000
treeherdermozilla-aurora@0931190cd725 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersSimonSapin
servo: Merge #9380 - Update cssparser (from servo:cssparserup); r=SimonSapin https://github.com/servo/rust-cssparser/pull/91 Source-Repo: https://github.com/servo/servo Source-Revision: 1ba1fb0b7f46472e1f37f4e3f2e7dde025fa9f1f
servo/components/canvas_traits/Cargo.toml
servo/components/layout/Cargo.toml
servo/components/msg/Cargo.toml
servo/components/script/Cargo.toml
servo/components/servo/Cargo.lock
servo/components/style/Cargo.toml
servo/components/style/font_face.rs
servo/components/style/lib.rs
servo/components/style/media_queries.rs
servo/components/style/properties.mako.rs
servo/components/style/stylesheets.rs
servo/components/style/values.rs
servo/components/style_traits/Cargo.toml
servo/components/style_traits/values.rs
servo/components/util/Cargo.toml
servo/components/util/cursor.rs
servo/ports/cef/Cargo.lock
servo/ports/geckolib/Cargo.lock
servo/ports/geckolib/Cargo.toml
servo/ports/gonk/Cargo.lock
servo/tests/unit/style/Cargo.toml
--- a/servo/components/canvas_traits/Cargo.toml
+++ b/servo/components/canvas_traits/Cargo.toml
@@ -30,12 +30,12 @@ features = [ "nightly" ]
 
 [dependencies.plugins]
 path = "../plugins"
 
 [dependencies.util]
 path = "../util"
 
 [dependencies]
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 euclid = {version = "0.4", features = ["plugins"]}
 serde_macros = "0.6"
 
--- a/servo/components/layout/Cargo.toml
+++ b/servo/components/layout/Cargo.toml
@@ -50,17 +50,17 @@ path = "../profile_traits"
 [dependencies.util]
 path = "../util"
 
 [dependencies.ipc-channel]
 git = "https://github.com/servo/ipc-channel"
 
 [dependencies]
 app_units = {version = "0.1", features = ["plugins"]}
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 log = "0.3"
 fnv = "1.0"
 bitflags = "0.3"
 rustc-serialize = "0.3"
 libc = "0.2"
 selectors = "0.2"
 smallvec = "0.1"
 string_cache = "0.2"
--- a/servo/components/msg/Cargo.toml
+++ b/servo/components/msg/Cargo.toml
@@ -16,16 +16,16 @@ features = ["plugins"]
 
 [dependencies.ipc-channel]
 git = "https://github.com/servo/ipc-channel"
 
 [dependencies.plugins]
 path = "../plugins"
 
 [dependencies]
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 bitflags = "0.3"
 hyper = { version = "0.7", features = [ "serde-serialization" ] }
 rustc-serialize = "0.3.4"
 euclid = {version = "0.4", features = ["plugins"]}
 serde = "0.6"
 serde_macros = "0.6"
 url = "0.5.2"
--- a/servo/components/script/Cargo.toml
+++ b/servo/components/script/Cargo.toml
@@ -59,17 +59,17 @@ git = "https://github.com/servo/ipc-chan
 git = "https://github.com/Ygg01/xml5ever"
 features = ["unstable"]
 
 [dependencies.gfx_traits]
 path = "../gfx_traits"
 
 [dependencies]
 app_units = {version = "0.1", features = ["plugins"]}
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 log = "0.3"
 encoding = "0.2"
 fnv = "1.0"
 hyper = { version = "0.7", features = [ "serde-serialization" ] }
 time = "0.1.12"
 bitflags = "0.3"
 rustc-serialize = "0.3"
 libc = "0.2"
--- a/servo/components/servo/Cargo.lock
+++ b/servo/components/servo/Cargo.lock
@@ -158,17 +158,17 @@ dependencies = [
  "util 0.0.1",
 ]
 
 [[package]]
 name = "canvas_traits"
 version = "0.0.1"
 dependencies = [
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx_traits 0.0.1",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)",
  "plugins 0.0.1",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -323,17 +323,17 @@ dependencies = [
 
 [[package]]
 name = "crossbeam"
 version = "0.1.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "cssparser"
-version = "0.4.0"
+version = "0.5.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -942,33 +942,33 @@ dependencies = [
 name = "layout"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "canvas 0.0.1",
  "canvas_traits 0.0.1",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx 0.0.1",
  "gfx_traits 0.0.1",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layout_traits 0.0.1",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "msg 0.0.1",
  "net_traits 0.0.1",
  "plugins 0.0.1",
  "profile_traits 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "script 0.0.1",
  "script_traits 0.0.1",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_json 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicode-bidi 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1125,17 +1125,17 @@ dependencies = [
  "libz-sys 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "msg"
 version = "0.0.1"
 dependencies = [
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1504,17 +1504,17 @@ name = "script"
 version = "0.0.1"
 dependencies = [
  "angle 0.1.0 (git+https://github.com/ecoal95/angle?branch=servo)",
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "canvas 0.0.1",
  "canvas_traits 0.0.1",
  "caseless 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "devtools_traits 0.0.1",
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx_traits 0.0.1",
  "html5ever 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "image 0.5.4 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1527,17 +1527,17 @@ dependencies = [
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)",
  "plugins 0.0.1",
  "profile_traits 0.0.1",
  "rand 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "ref_slice 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "script_traits 0.0.1",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "tendril 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicase 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1577,21 +1577,21 @@ dependencies = [
  "style_traits 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "selectors"
-version = "0.2.2"
+version = "0.2.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "quickersort 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1770,66 +1770,66 @@ dependencies = [
 ]
 
 [[package]]
 name = "style"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style_traits 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "style_tests"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "msg 0.0.1",
  "plugins 0.0.1",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "style_traits 0.0.1",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "style_traits"
 version = "0.0.1"
 dependencies = [
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "task_info"
@@ -1949,33 +1949,33 @@ dependencies = [
 
 [[package]]
 name = "util"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "getopts 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "html5ever 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "js 0.1.1 (git+https://github.com/servo/rust-mozjs)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rand 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "uuid 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
--- a/servo/components/style/Cargo.toml
+++ b/servo/components/style/Cargo.toml
@@ -15,17 +15,17 @@ path = "../plugins"
 [dependencies.util]
 path = "../util"
 
 [dependencies.style_traits]
 path = "../style_traits"
 
 [dependencies]
 app_units = {version = "0.1", features = ["plugins"]}
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 log = "0.3"
 encoding = "0.2"
 fnv = "1.0"
 rustc-serialize = "0.3"
 matches = "0.1"
 bitflags = "0.3"
 num = "0.1.24"
 lazy_static = "0.1.10"
--- a/servo/components/style/font_face.rs
+++ b/servo/components/style/font_face.rs
@@ -86,17 +86,17 @@ impl<'a, 'b> DeclarationParser for FontF
             "font-family" => {
                 Ok(FontFaceDescriptorDeclaration::Family(try!(
                             parse_one_family(input))))
             },
             "src" => {
                 Ok(FontFaceDescriptorDeclaration::Src(try!(input.parse_comma_separated(|input| {
                     parse_one_src(self.context, input)
                 }))))
-            }
+            },
             _ => Err(())
         }
     }
 }
 
 fn parse_one_src(context: &ParserContext, input: &mut Parser) -> Result<Source, ()> {
     if input.try(|input| input.expect_function_matching("local")).is_ok() {
         return Ok(Source::Local(try!(input.parse_nested_block(parse_one_family))))
--- a/servo/components/style/lib.rs
+++ b/servo/components/style/lib.rs
@@ -10,16 +10,18 @@
 #![feature(custom_attribute)]
 #![feature(custom_derive)]
 #![feature(plugin)]
 
 #![plugin(serde_macros)]
 #![plugin(serde_macros)]
 #![plugin(plugins)]
 
+#![recursion_limit = "500"]  // For match_ignore_ascii_case in PropertyDeclaration::parse
+
 extern crate app_units;
 #[macro_use]
 extern crate bitflags;
 extern crate core;
 #[macro_use]
 extern crate cssparser;
 extern crate encoding;
 extern crate euclid;
--- a/servo/components/style/media_queries.rs
+++ b/servo/components/style/media_queries.rs
@@ -128,17 +128,17 @@ impl Expression {
             try!(input.expect_colon());
             // TODO: Handle other media features
             match_ignore_ascii_case! { name,
                 "min-width" => {
                     Ok(Expression::Width(Range::Min(try!(specified::Length::parse_non_negative(input)))))
                 },
                 "max-width" => {
                     Ok(Expression::Width(Range::Max(try!(specified::Length::parse_non_negative(input)))))
-                }
+                },
                 _ => Err(())
             }
         })
     }
 }
 
 impl MediaQuery {
     fn parse(input: &mut Parser) -> Result<MediaQuery, ()> {
@@ -152,17 +152,17 @@ impl MediaQuery {
             None
         };
 
         let media_type;
         if let Ok(ident) = input.try(|input| input.expect_ident()) {
             media_type = match_ignore_ascii_case! { ident,
                 "screen" => MediaQueryType::MediaType(MediaType::Screen),
                 "print" => MediaQueryType::MediaType(MediaType::Print),
-                "all" => MediaQueryType::All
+                "all" => MediaQueryType::All,
                 _ => MediaQueryType::MediaType(MediaType::Unknown)
             }
         } else {
             // Media type is only optional if qualifier is not specified.
             if qualifier.is_some() {
                 return Err(())
             }
             media_type = MediaQueryType::All;
--- a/servo/components/style/properties.mako.rs
+++ b/servo/components/style/properties.mako.rs
@@ -473,38 +473,27 @@ pub mod longhands {
             }
         }
         #[inline] pub fn get_initial_value() -> computed_value::T {
             computed_value::T::${to_rust_ident(values[0])}
         }
         pub fn parse(_context: &ParserContext, input: &mut Parser)
                      -> Result<SpecifiedValue, ()> {
             match_ignore_ascii_case! { try!(input.expect_ident()),
-                % for value in values[:-1]:
+                % for value in values:
                     "${value}" => {
                         % if value in experimental_values:
                             if !::util::prefs::get_pref("layout.${value}.enabled")
                                 .as_boolean().unwrap_or(false) {
                                 return Err(())
                             }
                         % endif
                         Ok(computed_value::T::${to_rust_ident(value)})
                     },
                 % endfor
-                % for value in values[-1:]:
-                    "${value}" => {
-                        % if value in experimental_values:
-                            if !::util::prefs::get_pref("layout.${value}.enabled")
-                                .as_boolean().unwrap_or(false) {
-                                return Err(())
-                            }
-                        % endif
-                        Ok(computed_value::T::${to_rust_ident(value)})
-                    }
-                % endfor
                 _ => Err(())
             }
         }
 
         impl ToComputedValue for SpecifiedValue {
             type ComputedValue = computed_value::T;
 
             #[inline]
@@ -792,24 +781,19 @@ pub mod longhands {
         }
         /// baseline | sub | super | top | text-top | middle | bottom | text-bottom
         /// | <percentage> | <length>
         pub fn parse(_context: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue, ()> {
             input.try(specified::LengthOrPercentage::parse)
             .map(SpecifiedValue::LengthOrPercentage)
             .or_else(|()| {
                 match_ignore_ascii_case! { try!(input.expect_ident()),
-                    % for keyword in vertical_align_keywords[:-1]:
+                    % for keyword in vertical_align_keywords:
                         "${keyword}" => Ok(SpecifiedValue::${to_rust_ident(keyword)}),
                     % endfor
-
-                    // Hack to work around quirks of macro_rules parsing in match_ignore_ascii_case!
-                    % for keyword in vertical_align_keywords[-1:]:
-                        "${keyword}" => Ok(SpecifiedValue::${to_rust_ident(keyword)})
-                    % endfor
                     _ => Err(())
                 }
             })
         }
         pub mod computed_value {
             use app_units::Au;
             use std::fmt;
             use values::AuExtensionMethods;
@@ -1070,26 +1054,26 @@ pub mod longhands {
                                 let name = try!(input.expect_ident()).into_owned();
                                 try!(input.expect_comma());
                                 let separator = try!(input.expect_string()).into_owned();
                                 let style = input.try(|input| {
                                     try!(input.expect_comma());
                                     list_style_type::parse(context, input)
                                 }).unwrap_or(list_style_type::computed_value::T::decimal);
                                 Ok(ContentItem::Counters(name, separator, style))
-                            })
+                            }),
                             _ => return Err(())
                         }));
                     }
                     Ok(Token::Ident(ident)) => {
                         match_ignore_ascii_case! { ident,
                             "open-quote" => content.push(ContentItem::OpenQuote),
                             "close-quote" => content.push(ContentItem::CloseQuote),
                             "no-open-quote" => content.push(ContentItem::NoOpenQuote),
-                            "no-close-quote" => content.push(ContentItem::NoCloseQuote)
+                            "no-close-quote" => content.push(ContentItem::NoCloseQuote),
                             _ => return Err(())
                         }
                     }
                     Err(_) => break,
                     _ => return Err(())
                 }
             }
             if !content.is_empty() {
@@ -1741,17 +1725,17 @@ pub mod longhands {
                 }
 
                 pub fn from_atom(input: Atom) -> FontFamily {
                     let option = match_ignore_ascii_case! { &input,
                         super::SERIF => Some(FontFamily::Serif),
                         super::SANS_SERIF => Some(FontFamily::SansSerif),
                         super::CURSIVE => Some(FontFamily::Cursive),
                         super::FANTASY => Some(FontFamily::Fantasy),
-                        super::MONOSPACE => Some(FontFamily::Monospace)
+                        super::MONOSPACE => Some(FontFamily::Monospace),
                         _ => None
                     };
 
                     match option {
                         Some(family) => family,
                         None => FontFamily::FamilyName(input)
                     }
                 }
@@ -1792,17 +1776,17 @@ pub mod longhands {
             }
             let first_ident = try!(input.expect_ident());
 
             match_ignore_ascii_case! { first_ident,
                 SERIF => return Ok(FontFamily::Serif),
                 SANS_SERIF => return Ok(FontFamily::SansSerif),
                 CURSIVE => return Ok(FontFamily::Cursive),
                 FANTASY => return Ok(FontFamily::Fantasy),
-                MONOSPACE => return Ok(FontFamily::Monospace)
+                MONOSPACE => return Ok(FontFamily::Monospace),
                 _ => {}
             }
             let mut value = first_ident.into_owned();
             while let Ok(ident) = input.try(|input| input.expect_ident()) {
                 value.push_str(" ");
                 value.push_str(&ident);
             }
             Ok(FontFamily::FamilyName(Atom::from(&*value)))
@@ -1840,17 +1824,17 @@ pub mod longhands {
         }
         /// normal | bold | bolder | lighter | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900
         pub fn parse(_context: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue, ()> {
             input.try(|input| {
                 match_ignore_ascii_case! { try!(input.expect_ident()),
                     "bold" => Ok(SpecifiedValue::Weight700),
                     "normal" => Ok(SpecifiedValue::Weight400),
                     "bolder" => Ok(SpecifiedValue::Bolder),
-                    "lighter" => Ok(SpecifiedValue::Lighter)
+                    "lighter" => Ok(SpecifiedValue::Lighter),
                     _ => Err(())
                 }
             }).or_else(|()| {
                 match try!(input.expect_integer()) {
                     100 => Ok(SpecifiedValue::Weight100),
                     200 => Ok(SpecifiedValue::Weight200),
                     300 => Ok(SpecifiedValue::Weight300),
                     400 => Ok(SpecifiedValue::Weight400),
@@ -2246,17 +2230,17 @@ pub mod longhands {
                 match_ignore_ascii_case! { ident,
                     "underline" => if result.underline { return Err(()) }
                                   else { empty = false; result.underline = true },
                     "overline" => if result.overline { return Err(()) }
                                   else { empty = false; result.overline = true },
                     "line-through" => if result.line_through { return Err(()) }
                                       else { empty = false; result.line_through = true },
                     "blink" => if blink { return Err(()) }
-                               else { empty = false; blink = true }
+                               else { empty = false; blink = true },
                     _ => break
                 }
             }
             if !empty { Ok(result) } else { Err(()) }
         }
 
         fn cascade_property_custom(computed_value: &computed_value::T,
                                    _declaration: &PropertyDeclaration,
@@ -3544,17 +3528,17 @@ pub mod longhands {
                             "blur" => specified::Length::parse_non_negative(input).map(SpecifiedFilter::Blur),
                             "brightness" => parse_factor(input).map(SpecifiedFilter::Brightness),
                             "contrast" => parse_factor(input).map(SpecifiedFilter::Contrast),
                             "grayscale" => parse_factor(input).map(SpecifiedFilter::Grayscale),
                             "hue-rotate" => Angle::parse(input).map(SpecifiedFilter::HueRotate),
                             "invert" => parse_factor(input).map(SpecifiedFilter::Invert),
                             "opacity" => parse_factor(input).map(SpecifiedFilter::Opacity),
                             "saturate" => parse_factor(input).map(SpecifiedFilter::Saturate),
-                            "sepia" => parse_factor(input).map(SpecifiedFilter::Sepia)
+                            "sepia" => parse_factor(input).map(SpecifiedFilter::Sepia),
                             _ => Err(())
                         }
                     })));
                 } else if filters.is_empty() {
                     return Err(())
                 } else {
                     return Ok(SpecifiedValue(filters))
                 }
@@ -3991,17 +3975,17 @@ pub mod longhands {
                         }))
                     },
                     "perspective" => {
                         try!(input.parse_nested_block(|input| {
                             let d = try!(specified::Length::parse(input));
                             result.push(SpecifiedOperation::Perspective(d));
                             Ok(())
                         }))
-                    }
+                    },
                     _ => return Err(())
                 }
             }
 
             if !result.is_empty() {
                 Ok(SpecifiedValue(result))
             } else {
                 Err(())
@@ -4093,17 +4077,17 @@ pub mod longhands {
                         }
                     },
                     "bottom" => {
                         if vertical.is_none() {
                             vertical = Some(LengthOrPercentage::Percentage(Percentage(1.0)))
                         } else {
                             return Err(())
                         }
-                    }
+                    },
                     _ => return Err(())
                 }
                 Ok(())
             }) {
                 match LengthOrPercentage::parse(input) {
                     Ok(value) => {
                         if horizontal.is_none() {
                             horizontal = Some(value);
@@ -4330,17 +4314,17 @@ pub mod longhands {
             // According to to CSS-IMAGES-3, `optimizespeed` and `optimizequality` are synonyms for
             // `auto`.
             match_ignore_ascii_case! {
                 try!(input.expect_ident()),
                 "auto" => Ok(computed_value::T::Auto),
                 "optimizespeed" => Ok(computed_value::T::Auto),
                 "optimizequality" => Ok(computed_value::T::Auto),
                 "crisp-edges" => Ok(computed_value::T::CrispEdges),
-                "pixelated" => Ok(computed_value::T::Pixelated)
+                "pixelated" => Ok(computed_value::T::Pixelated),
                 _ => Err(())
             }
         }
 
         impl ToComputedValue for SpecifiedValue {
             type ComputedValue = computed_value::T;
 
             #[inline]
@@ -4579,35 +4563,35 @@ pub mod longhands {
                     "steps" => {
                         let (mut step_count, mut start_end) = (0, computed_value::StartEnd::Start);
                         try!(input.parse_nested_block(|input| {
                             step_count = try!(specified::parse_integer(input));
                             try!(input.expect_comma());
                             start_end = try!(match_ignore_ascii_case! {
                                 try!(input.expect_ident()),
                                 "start" => Ok(computed_value::StartEnd::Start),
-                                "end" => Ok(computed_value::StartEnd::End)
+                                "end" => Ok(computed_value::StartEnd::End),
                                 _ => Err(())
                             });
                             Ok(())
                         }));
                         Ok(TransitionTimingFunction::Steps(step_count as u32, start_end))
-                    }
+                    },
                     _ => Err(())
                 }
             }
             match_ignore_ascii_case! {
                 try!(input.expect_ident()),
                 "ease" => Ok(EASE),
                 "linear" => Ok(LINEAR),
                 "ease-in" => Ok(EASE_IN),
                 "ease-out" => Ok(EASE_OUT),
                 "ease-in-out" => Ok(EASE_IN_OUT),
                 "step-start" => Ok(STEP_START),
-                "step-end" => Ok(STEP_END)
+                "step-end" => Ok(STEP_END),
                 _ => Err(())
             }
         }
 
         pub fn parse(_: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue,()> {
             Ok(SpecifiedValue(try!(input.parse_comma_separated(parse_one))))
         }
     </%self:longhand>
@@ -4844,17 +4828,17 @@ pub mod longhands {
                 "text-indent" => Ok(TransitionProperty::TextIndent),
                 "text-shadow" => Ok(TransitionProperty::TextShadow),
                 "top" => Ok(TransitionProperty::Top),
                 "transform" => Ok(TransitionProperty::Transform),
                 "vertical-align" => Ok(TransitionProperty::VerticalAlign),
                 "visibility" => Ok(TransitionProperty::Visibility),
                 "width" => Ok(TransitionProperty::Width),
                 "word-spacing" => Ok(TransitionProperty::WordSpacing),
-                "z-index" => Ok(TransitionProperty::ZIndex)
+                "z-index" => Ok(TransitionProperty::ZIndex),
                 _ => Err(())
             }
         }
 
         pub fn parse(_: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue,()> {
             Ok(SpecifiedValue(try!(input.parse_comma_separated(parse_one))))
         }
 
@@ -5842,38 +5826,35 @@ pub enum CSSWideKeyword {
     UnsetKeyword,
 }
 
 impl CSSWideKeyword {
     pub fn parse(input: &mut Parser) -> Result<CSSWideKeyword, ()> {
         match_ignore_ascii_case! { try!(input.expect_ident()),
             "initial" => Ok(CSSWideKeyword::InitialKeyword),
             "inherit" => Ok(CSSWideKeyword::InheritKeyword),
-            "unset" => Ok(CSSWideKeyword::UnsetKeyword)
+            "unset" => Ok(CSSWideKeyword::UnsetKeyword),
             _ => Err(())
         }
     }
 }
 
 #[derive(Clone, Copy, Eq, PartialEq, Debug)]
 pub enum Shorthand {
     % for property in SHORTHANDS:
         ${property.camel_case},
     % endfor
 }
 
 impl Shorthand {
     pub fn from_name(name: &str) -> Option<Shorthand> {
         match_ignore_ascii_case! { name,
-            % for property in SHORTHANDS[:-1]:
+            % for property in SHORTHANDS:
                 "${property.name}" => Some(Shorthand::${property.camel_case}),
             % endfor
-            % for property in SHORTHANDS[-1:]:
-                "${property.name}" => Some(Shorthand::${property.camel_case})
-            % endfor
             _ => None
         }
     }
 
     pub fn longhands(&self) -> &'static [&'static str] {
         % for property in SHORTHANDS:
             static ${property.ident.upper()}: &'static [&'static str] = &[
                 % for sub in property.sub_properties:
@@ -6123,19 +6104,16 @@ impl PropertyDeclaration {
                         Err(()) => match shorthands::${shorthand.ident}::parse(context, input, result_list) {
                             Ok(()) => PropertyDeclarationParseResult::ValidOrIgnoredDeclaration,
                             Err(()) => PropertyDeclarationParseResult::InvalidValue,
                         }
                     }
                 },
             % endfor
 
-            // Hack to work around quirks of macro_rules parsing in match_ignore_ascii_case!
-            "_nonexistent" => PropertyDeclarationParseResult::UnknownProperty
-
             _ => PropertyDeclarationParseResult::UnknownProperty
         }
     }
 }
 
 pub mod style_structs {
     use super::longhands;
 
@@ -7006,20 +6984,19 @@ pub fn modify_style_for_inline_absolute_
         let mut style = Arc::make_mut(style);
         let effects_style = Arc::make_mut(&mut style.effects);
         effects_style.clip.0 = None
     }
 }
 
 pub fn is_supported_property(property: &str) -> bool {
     match_ignore_ascii_case! { property,
-        % for property in SHORTHANDS + LONGHANDS[:-1]:
+        % for property in SHORTHANDS + LONGHANDS:
             "${property.name}" => true,
         % endfor
-        "${LONGHANDS[-1].name}" => true
         _ => property.starts_with("--")
     }
 }
 
 #[macro_export]
 macro_rules! css_properties_accessors {
     ($macro_name: ident) => {
         $macro_name! {
--- a/servo/components/style/stylesheets.rs
+++ b/servo/components/style/stylesheets.rs
@@ -387,17 +387,17 @@ impl<'a> AtRuleParser for TopLevelRulePa
                     self.state.set(State::Namespaces);
 
                     let prefix = input.try(|input| input.expect_ident()).ok().map(|p| p.into_owned());
                     let url = Namespace(Atom::from(&*try!(input.expect_url_or_string())));
                     return Ok(AtRuleType::WithoutBlock(CSSRule::Namespace(prefix, url)))
                 } else {
                     return Err(())  // "@namespace must be before any rule but @charset and @import"
                 }
-            }
+            },
             _ => {}
         }
 
         self.state.set(State::Body);
         AtRuleParser::parse_prelude(&NestedRuleParser { context: &self.context }, name, input)
     }
 
     #[inline]
@@ -445,17 +445,17 @@ impl<'a, 'b> AtRuleParser for NestedRule
                 Ok(AtRuleType::WithBlock(AtRulePrelude::FontFace))
             },
             "viewport" => {
                 if ::util::prefs::get_pref("layout.viewport.enabled").as_boolean().unwrap_or(false) {
                     Ok(AtRuleType::WithBlock(AtRulePrelude::Viewport))
                 } else {
                     Err(())
                 }
-            }
+            },
             _ => Err(())
         }
     }
 
     fn parse_block(&self, prelude: AtRulePrelude, input: &mut Parser) -> Result<CSSRule, ()> {
         match prelude {
             AtRulePrelude::FontFace => {
                 parse_font_face_block(self.context, input).map(CSSRule::FontFace)
--- a/servo/components/style/values.rs
+++ b/servo/components/style/values.rs
@@ -45,17 +45,17 @@ macro_rules! define_numbered_css_keyword
         #[derive(Deserialize, Serialize)]
         pub enum $name {
             $( $variant = $value ),+
         }
 
         impl $name {
             pub fn parse(input: &mut ::cssparser::Parser) -> Result<$name, ()> {
                 match_ignore_ascii_case! { try!(input.expect_ident()),
-                    $( $css => Ok($name::$variant) ),+
+                    $( $css => Ok($name::$variant), )+
                     _ => Err(())
                 }
             }
         }
 
         impl ::cssparser::ToCss for $name {
             fn to_css<W>(&self, dest: &mut W) -> ::std::fmt::Result
             where W: ::std::fmt::Write {
@@ -327,17 +327,17 @@ pub mod specified {
                 "small" => Length::Absolute(Au::from_px(FONT_MEDIUM_PX) * 8 / 9),
                 "medium" => Length::Absolute(Au::from_px(FONT_MEDIUM_PX)),
                 "large" => Length::Absolute(Au::from_px(FONT_MEDIUM_PX) * 6 / 5),
                 "x-large" => Length::Absolute(Au::from_px(FONT_MEDIUM_PX) * 3 / 2),
                 "xx-large" => Length::Absolute(Au::from_px(FONT_MEDIUM_PX) * 2),
 
                 // https://github.com/servo/servo/issues/3423#issuecomment-56321664
                 "smaller" => Length::FontRelative(FontRelativeLength::Em(0.85)),
-                "larger" => Length::FontRelative(FontRelativeLength::Em(1.2))
+                "larger" => Length::FontRelative(FontRelativeLength::Em(1.2)),
                 _ => return None
             })
         }
 
         #[inline]
         fn parse_internal(input: &mut Parser, context: &AllowedNumericType) -> Result<Length, ()> {
             match try!(input.next()) {
                 Token::Dimension(ref value, ref unit) if context.is_ok(value.value) =>
@@ -368,17 +368,17 @@ pub mod specified {
                 "em" => Ok(Length::FontRelative(FontRelativeLength::Em(value))),
                 "ex" => Ok(Length::FontRelative(FontRelativeLength::Ex(value))),
                 "ch" => Ok(Length::FontRelative(FontRelativeLength::Ch(value))),
                 "rem" => Ok(Length::FontRelative(FontRelativeLength::Rem(value))),
                 // viewport percentages
                 "vw" => Ok(Length::ViewportPercentage(ViewportPercentageLength::Vw(value))),
                 "vh" => Ok(Length::ViewportPercentage(ViewportPercentageLength::Vh(value))),
                 "vmin" => Ok(Length::ViewportPercentage(ViewportPercentageLength::Vmin(value))),
-                "vmax" => Ok(Length::ViewportPercentage(ViewportPercentageLength::Vmax(value)))
+                "vmax" => Ok(Length::ViewportPercentage(ViewportPercentageLength::Vmax(value))),
                 _ => Err(())
             }
         }
         #[inline]
         pub fn from_px(px_value: CSSFloat) -> Length {
             Length::Absolute(Au((px_value * AU_PER_PX) as i32))
         }
     }
@@ -1101,17 +1101,17 @@ pub mod specified {
             .or_else(|()| {
                 match try!(input.next()) {
                     Token::Ident(value) => {
                         match_ignore_ascii_case! { value,
                             "center" => Ok(PositionComponent::Center),
                             "left" => Ok(PositionComponent::Left),
                             "right" => Ok(PositionComponent::Right),
                             "top" => Ok(PositionComponent::Top),
-                            "bottom" => Ok(PositionComponent::Bottom)
+                            "bottom" => Ok(PositionComponent::Bottom),
                             _ => Err(())
                         }
                     },
                     _ => Err(())
                 }
             })
         }
         #[inline]
@@ -1161,17 +1161,17 @@ pub mod specified {
             }
         }
 
         pub fn parse_dimension(value: CSSFloat, unit: &str) -> Result<Angle, ()> {
             match_ignore_ascii_case! { unit,
                 "deg" => Ok(Angle(value * RAD_PER_DEG)),
                 "grad" => Ok(Angle(value * RAD_PER_GRAD)),
                 "turn" => Ok(Angle(value * RAD_PER_TURN)),
-                "rad" => Ok(Angle(value))
+                "rad" => Ok(Angle(value)),
                  _ => Err(())
             }
         }
     }
 
     /// Specified values for an image according to CSS-IMAGES.
     #[derive(Clone, PartialEq, Debug, HeapSizeOf)]
     pub enum Image {
@@ -1197,17 +1197,17 @@ pub mod specified {
         pub fn parse(context: &ParserContext, input: &mut Parser) -> Result<Image, ()> {
             if let Ok(url) = input.try(|input| input.expect_url()) {
                 Ok(Image::Url(context.parse_url(&url)))
             } else {
                 match_ignore_ascii_case! { try!(input.expect_function()),
                     "linear-gradient" => {
                         Ok(Image::LinearGradient(try!(
                             input.parse_nested_block(LinearGradient::parse_function))))
-                    }
+                    },
                     _ => Err(())
                 }
             }
         }
     }
 
     /// Specified values for a CSS linear gradient.
     #[derive(Clone, PartialEq, Debug, HeapSizeOf)]
@@ -1340,28 +1340,28 @@ pub mod specified {
                                            "thin" =>
                                            Ok(BorderRadiusSize::circle(
                                                LengthOrPercentage::Length(Length::from_px(1.)))),
                                            "medium" =>
                                            Ok(BorderRadiusSize::circle(
                                                LengthOrPercentage::Length(Length::from_px(3.)))),
                                            "thick" =>
                                            Ok(BorderRadiusSize::circle(
-                                               LengthOrPercentage::Length(Length::from_px(5.))))
+                                               LengthOrPercentage::Length(Length::from_px(5.)))),
                                            _ => Err(())
                 }
             })
     }
 
     pub fn parse_border_width(input: &mut Parser) -> Result<Length, ()> {
         input.try(Length::parse_non_negative).or_else(|()| {
             match_ignore_ascii_case! { try!(input.expect_ident()),
                 "thin" => Ok(Length::from_px(1.)),
                 "medium" => Ok(Length::from_px(3.)),
-                "thick" => Ok(Length::from_px(5.))
+                "thick" => Ok(Length::from_px(5.)),
                 _ => Err(())
             }
         })
     }
 
     // The integer values here correspond to the border conflict resolution rules in CSS 2.1 ยง
     // 17.6.2.1. Higher values override lower values.
     define_numbered_css_keyword_enum! { BorderStyle:
--- a/servo/components/style_traits/Cargo.toml
+++ b/servo/components/style_traits/Cargo.toml
@@ -9,17 +9,17 @@ path = "lib.rs"
 
 [dependencies.util]
 path = "../util"
 
 [dependencies.plugins]
 path = "../plugins"
 
 [dependencies]
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 euclid = {version = "0.4", features = ["plugins"]}
 log = "0.3"
 lazy_static = "0.1.10"
 num = "0.1.24"
 rustc-serialize = "0.3"
 selectors = "0.2"
 serde = "0.6"
 serde_macros = "0.6"
--- a/servo/components/style_traits/values.rs
+++ b/servo/components/style_traits/values.rs
@@ -13,17 +13,17 @@ macro_rules! define_css_keyword_enum {
         #[derive(Deserialize, Serialize)]
         pub enum $name {
             $( $variant ),+
         }
 
         impl $name {
             pub fn parse(input: &mut ::cssparser::Parser) -> Result<$name, ()> {
                 match_ignore_ascii_case! { try!(input.expect_ident()),
-                                           $( $css => Ok($name::$variant) ),+
+                                           $( $css => Ok($name::$variant), )+
                                            _ => Err(())
                 }
             }
         }
 
         impl ::cssparser::ToCss for $name {
             fn to_css<W>(&self, dest: &mut W) -> ::std::fmt::Result
                 where W: ::std::fmt::Write {
--- a/servo/components/util/Cargo.toml
+++ b/servo/components/util/Cargo.toml
@@ -41,28 +41,28 @@ git = "https://github.com/servo/rust-lay
 features = ["plugins"]
 optional = true
 
 [dependencies.ipc-channel]
 git = "https://github.com/servo/ipc-channel"
 
 [dependencies]
 app_units = {version = "0.1", features = ["plugins"]}
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 log = "0.3"
 bitflags = "0.3"
 html5ever = { version = "0.2.1", features = ["unstable"], optional = true }
 libc = "0.2"
 rand = "0.3"
 rustc-serialize = "0.3"
 smallvec = "0.1"
 num_cpus = "0.2.2"
 num = "0.1.24"
 euclid = {version = "0.4", features = ["plugins"]}
-selectors = "0.2"
+selectors = "0.2.3"
 serde = "0.6"
 serde_macros = "0.6"
 string_cache = "0.2"
 lazy_static = "0.1"
 getopts = "0.2.11"
 hyper = { version = "0.7", optional = true }
 url = {version = "0.5.2", features = ["serde_serialization"]}
 uuid = "0.1.17"
--- a/servo/components/util/cursor.rs
+++ b/servo/components/util/cursor.rs
@@ -13,17 +13,17 @@ macro_rules! define_cursor {
         #[repr(u8)]
         pub enum Cursor {
             $( $variant = $value ),+
         }
 
         impl Cursor {
             pub fn from_css_keyword(keyword: &str) -> Result<Cursor, ()> {
                 match_ignore_ascii_case! { keyword,
-                    $( concat!($css) => Ok(Cursor::$variant) ),+
+                    $( concat!($css) => Ok(Cursor::$variant), )+
                     _ => Err(())
                 }
             }
         }
 
         impl ToCss for Cursor {
             fn to_css<W>(&self, dest: &mut W) -> ::std::fmt::Result where W: ::std::fmt::Write {
                 match *self {
--- a/servo/ports/cef/Cargo.lock
+++ b/servo/ports/cef/Cargo.lock
@@ -148,17 +148,17 @@ dependencies = [
  "util 0.0.1",
 ]
 
 [[package]]
 name = "canvas_traits"
 version = "0.0.1"
 dependencies = [
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx_traits 0.0.1",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)",
  "plugins 0.0.1",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -324,17 +324,17 @@ dependencies = [
 
 [[package]]
 name = "crossbeam"
 version = "0.1.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "cssparser"
-version = "0.4.0"
+version = "0.5.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -901,33 +901,33 @@ dependencies = [
 name = "layout"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "canvas 0.0.1",
  "canvas_traits 0.0.1",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx 0.0.1",
  "gfx_traits 0.0.1",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layout_traits 0.0.1",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "msg 0.0.1",
  "net_traits 0.0.1",
  "plugins 0.0.1",
  "profile_traits 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "script 0.0.1",
  "script_traits 0.0.1",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_json 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicode-bidi 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1084,17 +1084,17 @@ dependencies = [
  "libz-sys 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "msg"
 version = "0.0.1"
 dependencies = [
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1428,17 +1428,17 @@ name = "script"
 version = "0.0.1"
 dependencies = [
  "angle 0.1.0 (git+https://github.com/ecoal95/angle?branch=servo)",
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "canvas 0.0.1",
  "canvas_traits 0.0.1",
  "caseless 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "devtools_traits 0.0.1",
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx_traits 0.0.1",
  "html5ever 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "image 0.5.4 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1451,17 +1451,17 @@ dependencies = [
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)",
  "plugins 0.0.1",
  "profile_traits 0.0.1",
  "rand 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "ref_slice 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "script_traits 0.0.1",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "tendril 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicase 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1492,21 +1492,21 @@ dependencies = [
  "style_traits 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "selectors"
-version = "0.2.2"
+version = "0.2.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "quickersort 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1720,49 +1720,49 @@ dependencies = [
 ]
 
 [[package]]
 name = "style"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style_traits 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "style_traits"
 version = "0.0.1"
 dependencies = [
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "task_info"
@@ -1882,33 +1882,33 @@ dependencies = [
 
 [[package]]
 name = "util"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "getopts 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "html5ever 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "js 0.1.1 (git+https://github.com/servo/rust-mozjs)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rand 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "uuid 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
--- a/servo/ports/geckolib/Cargo.lock
+++ b/servo/ports/geckolib/Cargo.lock
@@ -1,20 +1,20 @@
 [root]
 name = "geckoservo"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
@@ -60,17 +60,17 @@ source = "registry+https://github.com/ru
 
 [[package]]
 name = "byteorder"
 version = "0.4.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "cssparser"
-version = "0.4.0"
+version = "0.5.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -307,21 +307,21 @@ dependencies = [
 
 [[package]]
 name = "rustc-serialize"
 version = "0.3.16"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "selectors"
-version = "0.2.2"
+version = "0.2.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "quickersort 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -368,49 +368,49 @@ dependencies = [
 ]
 
 [[package]]
 name = "style"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style_traits 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "style_traits"
 version = "0.0.1"
 dependencies = [
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "tenacious"
@@ -447,29 +447,29 @@ dependencies = [
 ]
 
 [[package]]
 name = "util"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "getopts 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rand 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "uuid 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
--- a/servo/ports/geckolib/Cargo.toml
+++ b/servo/ports/geckolib/Cargo.toml
@@ -6,17 +6,17 @@ authors = ["The Servo Project Developers
 [lib]
 name = "geckoservo"
 path = "lib.rs"
 crate-type = ["staticlib"]
 
 [dependencies]
 app_units = {version = "0.1", features = ["plugins"]}
 bitflags = "0.3"
-cssparser = { version = "0.4", features = [ "serde-serialization" ] }
+cssparser = { version = "0.5", features = [ "serde-serialization" ] }
 euclid = {version = "0.4", features = ["plugins"]}
 libc = "0.2"
 log = "0.3"
 num_cpus = "0.2.2"
 selectors = "0.2"
 smallvec = "0.1"
 string_cache = "0.2"
 url = "0.5.2"
--- a/servo/ports/gonk/Cargo.lock
+++ b/servo/ports/gonk/Cargo.lock
@@ -140,17 +140,17 @@ dependencies = [
  "util 0.0.1",
 ]
 
 [[package]]
 name = "canvas_traits"
 version = "0.0.1"
 dependencies = [
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx_traits 0.0.1",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)",
  "plugins 0.0.1",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -305,17 +305,17 @@ dependencies = [
 
 [[package]]
 name = "crossbeam"
 version = "0.1.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "cssparser"
-version = "0.4.0"
+version = "0.5.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -872,33 +872,33 @@ dependencies = [
 name = "layout"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "canvas 0.0.1",
  "canvas_traits 0.0.1",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx 0.0.1",
  "gfx_traits 0.0.1",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layout_traits 0.0.1",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "msg 0.0.1",
  "net_traits 0.0.1",
  "plugins 0.0.1",
  "profile_traits 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "script 0.0.1",
  "script_traits 0.0.1",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_json 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicode-bidi 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1055,17 +1055,17 @@ dependencies = [
  "libz-sys 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "msg"
 version = "0.0.1"
 dependencies = [
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1399,17 +1399,17 @@ name = "script"
 version = "0.0.1"
 dependencies = [
  "angle 0.1.0 (git+https://github.com/ecoal95/angle?branch=servo)",
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "canvas 0.0.1",
  "canvas_traits 0.0.1",
  "caseless 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "devtools_traits 0.0.1",
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gfx_traits 0.0.1",
  "html5ever 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "image 0.5.4 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1422,17 +1422,17 @@ dependencies = [
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)",
  "plugins 0.0.1",
  "profile_traits 0.0.1",
  "rand 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "ref_slice 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "script_traits 0.0.1",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style 0.0.1",
  "tendril 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicase 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1463,21 +1463,21 @@ dependencies = [
  "style_traits 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "selectors"
-version = "0.2.2"
+version = "0.2.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "quickersort 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1689,49 +1689,49 @@ dependencies = [
 ]
 
 [[package]]
 name = "style"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "encoding 0.2.32 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "style_traits 0.0.1",
  "time 0.1.34 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "style_traits"
 version = "0.0.1"
 dependencies = [
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "util 0.0.1",
 ]
 
 [[package]]
 name = "task_info"
@@ -1851,33 +1851,33 @@ dependencies = [
 
 [[package]]
 name = "util"
 version = "0.0.1"
 dependencies = [
  "app_units 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "azure 0.2.1 (git+https://github.com/servo/rust-azure)",
  "bitflags 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "getopts 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "html5ever 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "hyper 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "ipc-channel 0.1.0 (git+https://github.com/servo/ipc-channel)",
  "js 0.1.1 (git+https://github.com/servo/rust-mozjs)",
  "layers 0.2.0 (git+https://github.com/servo/rust-layers)",
  "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "num 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "plugins 0.0.1",
  "rand 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
- "selectors 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "selectors 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_macros 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "string_cache 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "uuid 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
--- a/servo/tests/unit/style/Cargo.toml
+++ b/servo/tests/unit/style/Cargo.toml
@@ -21,12 +21,12 @@ path = "../../../components/style"
 path = "../../../components/style_traits"
 
 [dependencies.util]
 path = "../../../components/util"
 
 [dependencies]
 app_units = {version = "0.1", features = ["plugins"]}
 url = "0.5.2"
-cssparser = "0.4"
+cssparser = "0.5"
 selectors = "0.2"
 string_cache = "0.2"
 euclid = {version = "0.4", features = ["plugins"]}