servo: Merge #14294 - Rename a few source files (from servo:renames); r=Wafflespeanut
authorSimon Sapin <simon.sapin@exyr.org>
Sun, 20 Nov 2016 09:21:52 -0600
changeset 340184 a9a0347dd8721594ee1353b7e496788d321eb01a
parent 340183 4b1b281874d66bb230da646c962088caed0bc9de
child 340185 bab3b47f68350bd534d877b7e31f475d98a32425
push id31307
push usergszorc@mozilla.com
push dateSat, 04 Feb 2017 00:59:06 +0000
treeherdermozilla-central@94079d43835f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersWafflespeanut
servo: Merge #14294 - Rename a few source files (from servo:renames); r=Wafflespeanut <!-- Please describe your changes on the following line: --> --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [ ] These changes fix #__ (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [x] These changes do not require tests because _____ <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> Source-Repo: https://github.com/servo/servo Source-Revision: 68b1d1d2860ac6c6e8c1c0dfe46af6790ca01dc8
servo/components/layout/animation.rs
servo/components/layout/construct.rs
servo/components/layout/flow.rs
servo/components/layout/fragment.rs
servo/components/layout/generated_content.rs
servo/components/layout/incremental.rs
servo/components/layout/query.rs
servo/components/layout/traversal.rs
servo/components/layout_thread/lib.rs
servo/components/script/dom/bindings/trace.rs
servo/components/script/dom/cssstyledeclaration.rs
servo/components/script/dom/document.rs
servo/components/script/dom/element.rs
servo/components/script/dom/node.rs
servo/components/script/dom/window.rs
servo/components/script/layout_wrapper.rs
servo/components/script_layout_interface/lib.rs
servo/components/script_layout_interface/message.rs
servo/components/script_layout_interface/wrapper_traits.rs
servo/components/style/context.rs
servo/components/style/data.rs
servo/components/style/dom.rs
servo/components/style/gecko/data.rs
servo/components/style/gecko/mod.rs
servo/components/style/gecko/selector_impl.rs
servo/components/style/gecko/selector_parser.rs
servo/components/style/gecko/snapshot.rs
servo/components/style/gecko/wrapper.rs
servo/components/style/lib.rs
servo/components/style/matching.rs
servo/components/style/parser.rs
servo/components/style/restyle_hints.rs
servo/components/style/selector_impl.rs
servo/components/style/selector_matching.rs
servo/components/style/selector_parser.rs
servo/components/style/servo/mod.rs
servo/components/style/servo/selector_impl.rs
servo/components/style/servo/selector_parser.rs
servo/components/style/stylesheets.rs
servo/components/style/stylist.rs
servo/docs/components/style.md
servo/ports/geckolib/glue.rs
servo/tests/unit/style/lib.rs
servo/tests/unit/style/parsing/selectors.rs
servo/tests/unit/style/selector_matching.rs
servo/tests/unit/style/stylist.rs
--- a/servo/components/layout/animation.rs
+++ b/servo/components/layout/animation.rs
@@ -9,17 +9,17 @@ use flow::{self, Flow};
 use gfx::display_list::OpaqueNode;
 use ipc_channel::ipc::IpcSender;
 use msg::constellation_msg::PipelineId;
 use script_traits::{AnimationState, ConstellationControlMsg, LayoutMsg as ConstellationMsg};
 use std::collections::HashMap;
 use std::sync::mpsc::Receiver;
 use style::animation::{Animation, update_style_for_animation};
 use style::dom::TRestyleDamage;
-use style::selector_impl::RestyleDamage;
+use style::selector_parser::RestyleDamage;
 use style::timer::Timer;
 
 /// Processes any new animations that were discovered after style recalculation.
 /// Also expire any old animations that have completed, inserting them into
 /// `expired_animations`.
 pub fn update_animation_state(constellation_chan: &IpcSender<ConstellationMsg>,
                               script_chan: &IpcSender<ConstellationControlMsg>,
                               running_animations: &mut HashMap<OpaqueNode, Vec<Animation>>,
--- a/servo/components/layout/construct.rs
+++ b/servo/components/layout/construct.rs
@@ -46,19 +46,19 @@ use std::mem;
 use std::sync::Arc;
 use std::sync::atomic::Ordering;
 use style::computed_values::{caption_side, display, empty_cells, float, list_style_image, list_style_position};
 use style::computed_values::content::ContentItem;
 use style::computed_values::position;
 use style::context::SharedStyleContext;
 use style::logical_geometry::Direction;
 use style::properties::{self, ServoComputedValues};
-use style::selector_impl::{PseudoElement, RestyleDamage};
-use style::selector_matching::Stylist;
+use style::selector_parser::{PseudoElement, RestyleDamage};
 use style::servo::restyle_damage::{BUBBLE_ISIZES, RECONSTRUCT_FLOW};
+use style::stylist::Stylist;
 use table::TableFlow;
 use table_caption::TableCaptionFlow;
 use table_cell::TableCellFlow;
 use table_colgroup::TableColGroupFlow;
 use table_row::TableRowFlow;
 use table_rowgroup::TableRowGroupFlow;
 use table_wrapper::TableWrapperFlow;
 use text::TextRunScanner;
--- a/servo/components/layout/flow.rs
+++ b/servo/components/layout/flow.rs
@@ -48,17 +48,17 @@ use std::iter::Zip;
 use std::slice::IterMut;
 use std::sync::Arc;
 use std::sync::atomic::Ordering;
 use style::computed_values::{clear, float, overflow_x, position, text_align};
 use style::context::SharedStyleContext;
 use style::dom::TRestyleDamage;
 use style::logical_geometry::{LogicalRect, LogicalSize, WritingMode};
 use style::properties::ServoComputedValues;
-use style::selector_impl::RestyleDamage;
+use style::selector_parser::RestyleDamage;
 use style::servo::restyle_damage::{RECONSTRUCT_FLOW, REFLOW, REFLOW_OUT_OF_FLOW, REPAINT, REPOSITION};
 use style::values::computed::LengthOrPercentageOrAuto;
 use table::{ColumnComputedInlineSize, ColumnIntrinsicInlineSize, TableFlow};
 use table_caption::TableCaptionFlow;
 use table_cell::TableCellFlow;
 use table_colgroup::TableColGroupFlow;
 use table_row::TableRowFlow;
 use table_rowgroup::TableRowGroupFlow;
--- a/servo/components/layout/fragment.rs
+++ b/servo/components/layout/fragment.rs
@@ -42,17 +42,17 @@ use style::arc_ptr_eq;
 use style::computed_values::{border_collapse, box_sizing, clear, color, display, mix_blend_mode};
 use style::computed_values::{overflow_wrap, overflow_x, position, text_decoration};
 use style::computed_values::{transform_style, vertical_align, white_space, word_break, z_index};
 use style::computed_values::content::ContentItem;
 use style::context::SharedStyleContext;
 use style::dom::TRestyleDamage;
 use style::logical_geometry::{Direction, LogicalMargin, LogicalRect, LogicalSize, WritingMode};
 use style::properties::ServoComputedValues;
-use style::selector_impl::RestyleDamage;
+use style::selector_parser::RestyleDamage;
 use style::servo::restyle_damage::RECONSTRUCT_FLOW;
 use style::str::char_is_whitespace;
 use style::values::Either;
 use style::values::computed::{LengthOrPercentage, LengthOrPercentageOrAuto};
 use style::values::computed::LengthOrPercentageOrNone;
 use text;
 use text::TextRunScanner;
 
--- a/servo/components/layout/generated_content.rs
+++ b/servo/components/layout/generated_content.rs
@@ -16,17 +16,17 @@ use gfx::display_list::OpaqueNode;
 use script_layout_interface::wrapper_traits::PseudoElementType;
 use smallvec::SmallVec;
 use std::collections::{HashMap, LinkedList};
 use std::sync::Arc;
 use style::computed_values::{display, list_style_type};
 use style::computed_values::content::ContentItem;
 use style::dom::TRestyleDamage;
 use style::properties::ServoComputedValues;
-use style::selector_impl::RestyleDamage;
+use style::selector_parser::RestyleDamage;
 use style::servo::restyle_damage::RESOLVE_GENERATED_CONTENT;
 use text::TextRunScanner;
 
 // Decimal styles per CSS-COUNTER-STYLES § 6.1:
 static DECIMAL: [char; 10] = [ '0', '1', '2', '3', '4', '5', '6', '7', '8', '9' ];
 // TODO(pcwalton): `decimal-leading-zero`
 static ARABIC_INDIC: [char; 10] = [ '٠', '١', '٢', '٣', '٤', '٥', '٦', '٧', '٨', '٩' ];
 // TODO(pcwalton): `armenian`, `upper-armenian`, `lower-armenian`
--- a/servo/components/layout/incremental.rs
+++ b/servo/components/layout/incremental.rs
@@ -1,16 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 use flow::{self, AFFECTS_COUNTERS, Flow, HAS_COUNTER_AFFECTING_CHILDREN, IS_ABSOLUTELY_POSITIONED};
 use style::computed_values::float;
 use style::dom::TRestyleDamage;
-use style::selector_impl::RestyleDamage;
+use style::selector_parser::RestyleDamage;
 use style::servo::restyle_damage::{REFLOW, RECONSTRUCT_FLOW};
 
 bitflags! {
     pub flags SpecialRestyleDamage: u8 {
         #[doc = "If this flag is set, we need to reflow the entire document. This is more or less a \
                  temporary hack to deal with cases that we don't handle incrementally yet."]
         const REFLOW_ENTIRE_DOCUMENT = 0x01,
     }
--- a/servo/components/layout/query.rs
+++ b/servo/components/layout/query.rs
@@ -27,18 +27,18 @@ use servo_atoms::Atom;
 use std::cmp::{min, max};
 use std::ops::Deref;
 use std::sync::{Arc, Mutex};
 use style::computed_values;
 use style::context::StyleContext;
 use style::logical_geometry::{WritingMode, BlockFlowDirection, InlineBaseDirection};
 use style::properties::longhands::{display, position};
 use style::properties::style_structs;
-use style::selector_impl::PseudoElement;
-use style::selector_matching::Stylist;
+use style::selector_parser::PseudoElement;
+use style::stylist::Stylist;
 use style_traits::ToCss;
 use style_traits::cursor::Cursor;
 use wrapper::{LayoutNodeHelpers, LayoutNodeLayoutData};
 
 /// Mutable data belonging to the LayoutThread.
 ///
 /// This needs to be protected by a mutex so we can do fast RPCs.
 pub struct LayoutThreadData {
--- a/servo/components/layout/traversal.rs
+++ b/servo/components/layout/traversal.rs
@@ -11,17 +11,17 @@ use flow::{self, PreorderFlowTraversal};
 use flow::{CAN_BE_FRAGMENTED, Flow, ImmutableFlowUtils, PostorderFlowTraversal};
 use gfx::display_list::OpaqueNode;
 use script_layout_interface::wrapper_traits::{LayoutNode, ThreadSafeLayoutNode};
 use std::mem;
 use style::atomic_refcell::AtomicRefCell;
 use style::context::{LocalStyleContext, SharedStyleContext, StyleContext};
 use style::data::ElementData;
 use style::dom::{StylingMode, TElement, TNode};
-use style::selector_impl::RestyleDamage;
+use style::selector_parser::RestyleDamage;
 use style::servo::restyle_damage::{BUBBLE_ISIZES, REFLOW, REFLOW_OUT_OF_FLOW, REPAINT};
 use style::traversal::{DomTraversalContext, put_thread_local_bloom_filter};
 use style::traversal::{recalc_style_at, remove_from_bloom_filter};
 use style::traversal::take_thread_local_bloom_filter;
 use util::opts;
 use wrapper::{GetRawData, LayoutNodeHelpers, LayoutNodeLayoutData};
 
 pub struct RecalcStyleAndConstructFlows<'lc> {
--- a/servo/components/layout_thread/lib.rs
+++ b/servo/components/layout_thread/lib.rs
@@ -106,19 +106,19 @@ use std::sync::atomic::{AtomicUsize, Ord
 use std::sync::mpsc::{Receiver, Sender, channel};
 use style::animation::Animation;
 use style::context::{LocalStyleContextCreationInfo, ReflowGoal, SharedStyleContext};
 use style::dom::{TElement, TNode};
 use style::error_reporting::{ParseErrorReporter, StdoutErrorReporter};
 use style::logical_geometry::LogicalPoint;
 use style::media_queries::{Device, MediaType};
 use style::parser::ParserContextExtraData;
-use style::selector_matching::Stylist;
 use style::servo::restyle_damage::{REFLOW, REFLOW_OUT_OF_FLOW, REPAINT, REPOSITION, STORE_OVERFLOW};
 use style::stylesheets::{Origin, Stylesheet, UserAgentStylesheets};
+use style::stylist::Stylist;
 use style::thread_state;
 use style::timer::Timer;
 use util::geometry::max_rect;
 use util::opts;
 use util::prefs::PREFS;
 use util::resource_files::read_resource_file;
 use util::thread;
 
--- a/servo/components/script/dom/bindings/trace.rs
+++ b/servo/components/script/dom/bindings/trace.rs
@@ -92,17 +92,17 @@ use std::rc::Rc;
 use std::sync::Arc;
 use std::sync::atomic::{AtomicBool, AtomicUsize};
 use std::sync::mpsc::{Receiver, Sender};
 use std::time::{SystemTime, Instant};
 use style::attr::{AttrIdentifier, AttrValue, LengthOrPercentageOrAuto};
 use style::element_state::*;
 use style::media_queries::MediaList;
 use style::properties::PropertyDeclarationBlock;
-use style::selector_impl::{PseudoElement, Snapshot};
+use style::selector_parser::{PseudoElement, Snapshot};
 use style::values::specified::Length;
 use time::Duration;
 use url::Origin as UrlOrigin;
 use uuid::Uuid;
 use webrender_traits::{WebGLBufferId, WebGLError, WebGLFramebufferId, WebGLProgramId};
 use webrender_traits::{WebGLRenderbufferId, WebGLShaderId, WebGLTextureId};
 
 /// A trait to allow tracing (only) DOM objects.
--- a/servo/components/script/dom/cssstyledeclaration.rs
+++ b/servo/components/script/dom/cssstyledeclaration.rs
@@ -13,17 +13,17 @@ use dom::node::{Node, NodeDamage, window
 use dom::window::Window;
 use parking_lot::RwLock;
 use servo_atoms::Atom;
 use std::ascii::AsciiExt;
 use std::sync::Arc;
 use style::parser::ParserContextExtraData;
 use style::properties::{Shorthand, Importance, PropertyDeclarationBlock};
 use style::properties::{is_supported_property, parse_one_declaration, parse_style_attribute};
-use style::selector_impl::PseudoElement;
+use style::selector_parser::PseudoElement;
 use style_traits::ToCss;
 
 // http://dev.w3.org/csswg/cssom/#the-cssstyledeclaration-interface
 #[dom_struct]
 pub struct CSSStyleDeclaration {
     reflector_: Reflector,
     owner: JS<Element>,
     readonly: bool,
--- a/servo/components/script/dom/document.rs
+++ b/servo/components/script/dom/document.rs
@@ -119,17 +119,17 @@ use std::default::Default;
 use std::iter::once;
 use std::mem;
 use std::rc::Rc;
 use std::sync::Arc;
 use std::time::{Duration, Instant};
 use style::attr::AttrValue;
 use style::context::ReflowGoal;
 use style::restyle_hints::RestyleHint;
-use style::selector_impl::{RestyleDamage, Snapshot};
+use style::selector_parser::{RestyleDamage, Snapshot};
 use style::str::{split_html_space_chars, str_join};
 use style::stylesheets::Stylesheet;
 use time;
 use url::percent_encoding::percent_decode;
 use util::prefs::PREFS;
 
 pub enum TouchEventResult {
     Processed(bool),
--- a/servo/components/script/dom/element.rs
+++ b/servo/components/script/dom/element.rs
@@ -87,19 +87,19 @@ use style::attr::{AttrValue, LengthOrPer
 use style::dom::TRestyleDamage;
 use style::element_state::*;
 use style::matching::{common_style_affecting_attributes, rare_style_affecting_attributes};
 use style::parser::ParserContextExtraData;
 use style::properties::{DeclaredValue, Importance};
 use style::properties::{PropertyDeclaration, PropertyDeclarationBlock, parse_style_attribute};
 use style::properties::longhands::{background_image, border_spacing, font_family, font_size, overflow_x};
 use style::restyle_hints::RESTYLE_SELF;
-use style::selector_impl::{NonTSPseudoClass, RestyleDamage, ServoSelectorImpl};
-use style::selector_matching::ApplicableDeclarationBlock;
+use style::selector_parser::{NonTSPseudoClass, RestyleDamage, ServoSelectorImpl};
 use style::sink::Push;
+use style::stylist::ApplicableDeclarationBlock;
 use style::values::CSSFloat;
 use style::values::specified::{self, CSSColor, CSSRGBA, LengthOrPercentage};
 
 // TODO: Update focus state when the top-level browsing context gains or loses system focus,
 // and when the element enters or leaves a browsing context container.
 // https://html.spec.whatwg.org/multipage/#selector-focus
 
 #[dom_struct]
--- a/servo/components/script/dom/node.rs
+++ b/servo/components/script/dom/node.rs
@@ -78,17 +78,17 @@ use std::borrow::ToOwned;
 use std::cell::{Cell, UnsafeCell};
 use std::cmp::max;
 use std::default::Default;
 use std::iter;
 use std::mem;
 use std::ops::Range;
 use std::sync::Arc;
 use style::dom::OpaqueNode;
-use style::selector_impl::ServoSelectorImpl;
+use style::selector_parser::ServoSelectorImpl;
 use style::stylesheets::Stylesheet;
 use style::thread_state;
 use uuid::Uuid;
 
 //
 // The basic Node structure
 //
 
--- a/servo/components/script/dom/window.rs
+++ b/servo/components/script/dom/window.rs
@@ -87,17 +87,17 @@ use std::rc::Rc;
 use std::sync::{Arc, Mutex};
 use std::sync::atomic::{AtomicBool, Ordering};
 use std::sync::mpsc::{Sender, channel};
 use std::sync::mpsc::TryRecvError::{Disconnected, Empty};
 use style::context::ReflowGoal;
 use style::error_reporting::ParseErrorReporter;
 use style::media_queries;
 use style::properties::longhands::overflow_x;
-use style::selector_impl::PseudoElement;
+use style::selector_parser::PseudoElement;
 use style::str::HTML_SPACE_CHARACTERS;
 use task_source::dom_manipulation::DOMManipulationTaskSource;
 use task_source::file_reading::FileReadingTaskSource;
 use task_source::history_traversal::HistoryTraversalTaskSource;
 use task_source::networking::NetworkingTaskSource;
 use task_source::user_interaction::UserInteractionTaskSource;
 use time;
 use timers::{IsInterval, TimerCallback};
--- a/servo/components/script/layout_wrapper.rs
+++ b/servo/components/script/layout_wrapper.rs
@@ -61,20 +61,20 @@ use style::atomic_refcell::{AtomicRef, A
 use style::attr::AttrValue;
 use style::computed_values::display;
 use style::context::SharedStyleContext;
 use style::data::ElementData;
 use style::dom::{LayoutIterator, NodeInfo, OpaqueNode, PresentationalHintsSynthetizer, TElement, TNode};
 use style::dom::UnsafeNode;
 use style::element_state::*;
 use style::properties::{ComputedValues, PropertyDeclarationBlock};
-use style::selector_impl::{NonTSPseudoClass, PseudoElement, RestyleDamage, ServoSelectorImpl};
-use style::selector_matching::ApplicableDeclarationBlock;
+use style::selector_parser::{NonTSPseudoClass, PseudoElement, RestyleDamage, ServoSelectorImpl};
 use style::sink::Push;
 use style::str::is_whitespace;
+use style::stylist::ApplicableDeclarationBlock;
 
 #[derive(Copy, Clone)]
 pub struct ServoLayoutNode<'a> {
     /// The wrapped node.
     node: LayoutJS<Node>,
 
     /// Being chained to a PhantomData prevents `LayoutNode`s from escaping.
     chain: PhantomData<&'a ()>,
--- a/servo/components/script_layout_interface/lib.rs
+++ b/servo/components/script_layout_interface/lib.rs
@@ -47,17 +47,17 @@ pub mod wrapper_traits;
 use canvas_traits::CanvasMsg;
 use core::nonzero::NonZero;
 use ipc_channel::ipc::IpcSender;
 use libc::c_void;
 use std::sync::atomic::AtomicIsize;
 use style::atomic_refcell::AtomicRefCell;
 use style::data::ElementData;
 use style::dom::TRestyleDamage;
-use style::selector_impl::RestyleDamage;
+use style::selector_parser::RestyleDamage;
 
 pub struct PartialPersistentLayoutData {
     /// Data that the style system associates with a node. When the
     /// style system is being used standalone, this is all that hangs
     /// off the node. This must be first to permit the various
     /// transmutations between ElementData and PersistentLayoutData.
     pub style_data: ElementData,
 
--- a/servo/components/script_layout_interface/message.rs
+++ b/servo/components/script_layout_interface/message.rs
@@ -14,17 +14,17 @@ use profile_traits::mem::ReportsChan;
 use rpc::LayoutRPC;
 use script_traits::{ConstellationControlMsg, LayoutControlMsg};
 use script_traits::{LayoutMsg as ConstellationMsg, StackingContextScrollState, WindowSizeData};
 use servo_atoms::Atom;
 use servo_url::ServoUrl;
 use std::sync::Arc;
 use std::sync::mpsc::{Receiver, Sender};
 use style::context::ReflowGoal;
-use style::selector_impl::PseudoElement;
+use style::selector_parser::PseudoElement;
 use style::stylesheets::Stylesheet;
 
 /// Asynchronous messages that script can send to layout.
 pub enum Msg {
     /// Adds the given stylesheet to the document.
     AddStylesheet(Arc<Stylesheet>),
 
     /// Puts a document into quirks mode, causing the quirks mode stylesheet to be loaded.
--- a/servo/components/script_layout_interface/wrapper_traits.rs
+++ b/servo/components/script_layout_interface/wrapper_traits.rs
@@ -17,17 +17,17 @@ use std::fmt::Debug;
 use std::sync::Arc;
 use style::atomic_refcell::AtomicRefCell;
 use style::computed_values::display;
 use style::context::SharedStyleContext;
 use style::data::ElementData;
 use style::dom::{LayoutIterator, NodeInfo, PresentationalHintsSynthetizer, TNode};
 use style::dom::OpaqueNode;
 use style::properties::ServoComputedValues;
-use style::selector_impl::{PseudoElement, PseudoElementCascadeType, RestyleDamage, ServoSelectorImpl};
+use style::selector_parser::{PseudoElement, PseudoElementCascadeType, RestyleDamage, ServoSelectorImpl};
 
 #[derive(Copy, PartialEq, Clone, Debug)]
 pub enum PseudoElementType<T> {
     Normal,
     Before(T),
     After(T),
     DetailsSummary(T),
     DetailsContent(T),
--- a/servo/components/style/context.rs
+++ b/servo/components/style/context.rs
@@ -6,21 +6,21 @@
 
 use animation::Animation;
 use app_units::Au;
 use dom::OpaqueNode;
 use error_reporting::ParseErrorReporter;
 use euclid::Size2D;
 use matching::StyleSharingCandidateCache;
 use parking_lot::RwLock;
-use selector_matching::Stylist;
 use std::cell::RefCell;
 use std::collections::HashMap;
 use std::sync::{Arc, Mutex};
 use std::sync::mpsc::Sender;
+use stylist::Stylist;
 use timer::Timer;
 
 /// This structure is used to create a local style context from a shared one.
 pub struct LocalStyleContextCreationInfo {
     new_animations_sender: Sender<Animation>,
 }
 
 impl LocalStyleContextCreationInfo {
--- a/servo/components/style/data.rs
+++ b/servo/components/style/data.rs
@@ -1,17 +1,17 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 //! Per-node data used in style calculation.
 
 use properties::ComputedValues;
 use rule_tree::StrongRuleNode;
-use selector_impl::PseudoElement;
+use selector_parser::PseudoElement;
 use std::collections::HashMap;
 use std::hash::BuildHasherDefault;
 use std::mem;
 use std::ops::{Deref, DerefMut};
 use std::sync::Arc;
 
 type PseudoStylesInner = HashMap<PseudoElement, (Arc<ComputedValues>, StrongRuleNode),
                                  BuildHasherDefault<::fnv::FnvHasher>>;
--- a/servo/components/style/dom.rs
+++ b/servo/components/style/dom.rs
@@ -9,22 +9,22 @@
 use {Atom, Namespace, LocalName};
 use atomic_refcell::{AtomicRef, AtomicRefCell};
 use data::{ElementStyles, ElementData};
 use element_state::ElementState;
 use parking_lot::RwLock;
 use properties::{ComputedValues, PropertyDeclarationBlock};
 use properties::longhands::display::computed_value as display;
 use restyle_hints::{RESTYLE_DESCENDANTS, RESTYLE_LATER_SIBLINGS, RESTYLE_SELF, RestyleHint};
-use selector_impl::{ElementExt, PseudoElement, RestyleDamage};
-use selector_matching::ApplicableDeclarationBlock;
+use selector_parser::{ElementExt, PseudoElement, RestyleDamage};
 use sink::Push;
 use std::fmt::Debug;
 use std::ops::BitOr;
 use std::sync::Arc;
+use stylist::ApplicableDeclarationBlock;
 use traversal::DomTraversalContext;
 use util::opts;
 
 pub use style_traits::UnsafeNode;
 
 /// An opaque handle to a node, which, unlike UnsafeNode, cannot be transformed
 /// back into a non-opaque representation. The only safe operation that can be
 /// performed on this node is to compare it to another opaque handle or to another
--- a/servo/components/style/gecko/data.rs
+++ b/servo/components/style/gecko/data.rs
@@ -7,24 +7,24 @@ use atomic_refcell::{AtomicRef, AtomicRe
 use dom::OpaqueNode;
 use euclid::size::TypedSize2D;
 use gecko_bindings::bindings::RawServoStyleSet;
 use gecko_bindings::sugar::ownership::{HasBoxFFI, HasFFI, HasSimpleFFI};
 use media_queries::{Device, MediaType};
 use num_cpus;
 use parking_lot::RwLock;
 use rayon;
-use selector_matching::Stylist;
 use std::cmp;
 use std::collections::HashMap;
 use std::env;
 use std::sync::Arc;
 use std::sync::mpsc::{Receiver, Sender, channel};
 use style_traits::ViewportPx;
 use stylesheets::Stylesheet;
+use stylist::Stylist;
 
 pub struct PerDocumentStyleDataImpl {
     /// Rule processor.
     pub stylist: Arc<Stylist>,
 
     /// List of stylesheets, mirrored from Gecko.
     pub stylesheets: Vec<Arc<Stylesheet>>,
 
--- a/servo/components/style/gecko/mod.rs
+++ b/servo/components/style/gecko/mod.rs
@@ -7,10 +7,10 @@ pub mod context;
 pub mod data;
 pub mod restyle_damage;
 pub mod snapshot;
 pub mod snapshot_helpers;
 pub mod traversal;
 pub mod wrapper;
 
 pub mod conversions;
-pub mod selector_impl;
+pub mod selector_parser;
 pub mod values;
rename from servo/components/style/gecko/selector_impl.rs
rename to servo/components/style/gecko/selector_parser.rs
--- a/servo/components/style/gecko/selector_impl.rs
+++ b/servo/components/style/gecko/selector_parser.rs
@@ -1,16 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 use cssparser::ToCss;
 use element_state::ElementState;
-use selector_impl::{attr_equals_selector_is_shareable, attr_exists_selector_is_shareable};
-use selector_impl::PseudoElementCascadeType;
+use selector_parser::{attr_equals_selector_is_shareable, attr_exists_selector_is_shareable};
+use selector_parser::PseudoElementCascadeType;
 use selectors::parser::{AttrSelector, ParserContext, SelectorImpl};
 use std::fmt;
 use string_cache::{Atom, Namespace, WeakAtom, WeakNamespace};
 
 #[derive(Debug, Clone, PartialEq, Eq)]
 pub struct GeckoSelectorImpl;
 
 /// NOTE: The boolean field represents whether this element is an anonymous box.
--- a/servo/components/style/gecko/snapshot.rs
+++ b/servo/components/style/gecko/snapshot.rs
@@ -4,17 +4,17 @@
 
 use element_state::ElementState;
 use gecko::snapshot_helpers;
 use gecko::wrapper::AttrSelectorHelpers;
 use gecko_bindings::bindings;
 use gecko_bindings::structs::ServoElementSnapshot;
 use gecko_bindings::structs::ServoElementSnapshotFlags as Flags;
 use restyle_hints::ElementSnapshot;
-use selector_impl::TheSelectorImpl;
+use selector_parser::TheSelectorImpl;
 use selectors::parser::AttrSelector;
 use string_cache::Atom;
 
 // NB: This is sound, in some sense, because during computation of restyle hints
 // the snapshot is kept alive by the modified elements table.
 #[derive(Debug)]
 pub struct GeckoElementSnapshot(*mut ServoElementSnapshot);
 
--- a/servo/components/style/gecko/wrapper.rs
+++ b/servo/components/style/gecko/wrapper.rs
@@ -7,17 +7,17 @@
 
 use atomic_refcell::{AtomicRef, AtomicRefCell};
 use data::ElementData;
 use dom::{LayoutIterator, NodeInfo, TElement, TNode, UnsafeNode};
 use dom::{OpaqueNode, PresentationalHintsSynthetizer};
 use element_state::ElementState;
 use error_reporting::StdoutErrorReporter;
 use gecko::restyle_damage::GeckoRestyleDamage;
-use gecko::selector_impl::{GeckoSelectorImpl, NonTSPseudoClass, PseudoElement};
+use gecko::selector_parser::{GeckoSelectorImpl, NonTSPseudoClass, PseudoElement};
 use gecko::snapshot_helpers;
 use gecko_bindings::bindings;
 use gecko_bindings::bindings::{Gecko_DropStyleChildrenIterator, Gecko_MaybeCreateStyleChildrenIterator};
 use gecko_bindings::bindings::{Gecko_ElementState, Gecko_GetLastChild, Gecko_GetNextStyleChild};
 use gecko_bindings::bindings::{Gecko_GetServoDeclarationBlock, Gecko_IsHTMLElementInHTMLDocument};
 use gecko_bindings::bindings::{Gecko_IsLink, Gecko_IsRootElement};
 use gecko_bindings::bindings::{Gecko_IsUnvisitedLink, Gecko_IsVisitedLink, Gecko_Namespace};
 use gecko_bindings::bindings::{RawGeckoElement, RawGeckoNode};
@@ -27,26 +27,26 @@ use gecko_bindings::bindings::Gecko_SetN
 use gecko_bindings::bindings::Gecko_StoreStyleDifference;
 use gecko_bindings::structs;
 use gecko_bindings::structs::{NODE_HAS_DIRTY_DESCENDANTS_FOR_SERVO, NODE_IS_DIRTY_FOR_SERVO};
 use gecko_bindings::structs::{nsIAtom, nsIContent, nsStyleContext};
 use parking_lot::RwLock;
 use parser::ParserContextExtraData;
 use properties::{ComputedValues, parse_style_attribute};
 use properties::PropertyDeclarationBlock;
-use selector_impl::ElementExt;
-use selector_matching::ApplicableDeclarationBlock;
+use selector_parser::ElementExt;
 use selectors::Element;
 use selectors::parser::{AttrSelector, NamespaceConstraint};
 use servo_url::ServoUrl;
 use sink::Push;
 use std::fmt;
 use std::ptr;
 use std::sync::Arc;
 use string_cache::{Atom, Namespace, WeakAtom, WeakNamespace};
+use stylist::ApplicableDeclarationBlock;
 
 // Important: We don't currently refcount the DOM, because the wrapper lifetime
 // magic guarantees that our LayoutFoo references won't outlive the root, and
 // we don't mutate any of the references on the Gecko side during restyle. We
 // could implement refcounting if need be (at a potentially non-trivial
 // performance cost) by implementing Drop and making LayoutFoo non-Copy.
 #[derive(Clone, Copy)]
 pub struct GeckoNode<'ln>(pub &'ln RawGeckoNode);
--- a/servo/components/style/lib.rs
+++ b/servo/components/style/lib.rs
@@ -109,18 +109,18 @@ pub mod logical_geometry;
 pub mod matching;
 pub mod media_queries;
 pub mod owning_handle;
 pub mod parallel;
 pub mod parser;
 pub mod refcell;
 pub mod restyle_hints;
 pub mod rule_tree;
-pub mod selector_impl;
-pub mod selector_matching;
+pub mod selector_parser;
+pub mod stylist;
 #[cfg(feature = "servo")] #[allow(unsafe_code)] pub mod servo;
 pub mod sequential;
 pub mod sink;
 pub mod str;
 pub mod stylesheets;
 pub mod thread_state;
 mod tid;
 pub mod timer;
--- a/servo/components/style/matching.rs
+++ b/servo/components/style/matching.rs
@@ -12,27 +12,27 @@ use atomic_refcell::AtomicRefMut;
 use cache::LRUCache;
 use cascade_info::CascadeInfo;
 use context::{SharedStyleContext, StyleContext};
 use data::{ElementData, ElementStyles, PseudoStyles};
 use dom::{TElement, TNode, TRestyleDamage, UnsafeNode};
 use properties::{CascadeFlags, ComputedValues, SHAREABLE, cascade};
 use properties::longhands::display::computed_value as display;
 use rule_tree::StrongRuleNode;
-use selector_impl::{PseudoElement, RestyleDamage, TheSelectorImpl};
-use selector_matching::ApplicableDeclarationBlock;
+use selector_parser::{PseudoElement, RestyleDamage, TheSelectorImpl};
 use selectors::MatchAttr;
 use selectors::bloom::BloomFilter;
 use selectors::matching::{AFFECTED_BY_PSEUDO_ELEMENTS, MatchingReason, StyleRelations};
 use sink::ForgetfulSink;
 use std::collections::HashMap;
 use std::hash::BuildHasherDefault;
 use std::mem;
 use std::slice::IterMut;
 use std::sync::Arc;
+use stylist::ApplicableDeclarationBlock;
 use util::opts;
 
 fn create_common_style_affecting_attributes_from_element<E: TElement>(element: &E)
                                                          -> CommonStyleAffectingAttributes {
     let mut flags = CommonStyleAffectingAttributes::empty();
     for attribute_info in &common_style_affecting_attributes() {
         match attribute_info.mode {
             CommonStyleAffectingAttributeMode::IsPresent(flag) => {
--- a/servo/components/style/parser.rs
+++ b/servo/components/style/parser.rs
@@ -3,17 +3,17 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 //! The context within which CSS code is parsed.
 
 use cssparser::{Parser, SourcePosition};
 use error_reporting::ParseErrorReporter;
 #[cfg(feature = "gecko")]
 use gecko_bindings::sugar::refptr::{GeckoArcPrincipal, GeckoArcURI};
-use selector_impl::TheSelectorImpl;
+use selector_parser::TheSelectorImpl;
 use selectors::parser::ParserContext as SelectorParserContext;
 use servo_url::ServoUrl;
 use stylesheets::Origin;
 
 #[cfg(not(feature = "gecko"))]
 pub struct ParserContextExtraData;
 
 #[cfg(feature = "gecko")]
--- a/servo/components/style/restyle_hints.rs
+++ b/servo/components/style/restyle_hints.rs
@@ -3,17 +3,17 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 //! Restyle hints: an optimization to avoid unnecessarily matching selectors.
 
 use Atom;
 use element_state::*;
 #[cfg(feature = "servo")]
 use heapsize::HeapSizeOf;
-use selector_impl::{AttrValue, ElementExt, NonTSPseudoClass, Snapshot, TheSelectorImpl};
+use selector_parser::{AttrValue, ElementExt, NonTSPseudoClass, Snapshot, TheSelectorImpl};
 use selectors::{Element, MatchAttr};
 use selectors::matching::{MatchingReason, StyleRelations};
 use selectors::matching::matches_complex_selector;
 use selectors::parser::{AttrSelector, Combinator, ComplexSelector, SelectorImpl, SimpleSelector};
 use std::clone::Clone;
 use std::sync::Arc;
 
 /// When the ElementState of an element (like IN_HOVER_STATE) changes, certain
rename from servo/components/style/selector_impl.rs
rename to servo/components/style/selector_parser.rs
--- a/servo/components/style/selector_impl.rs
+++ b/servo/components/style/selector_parser.rs
@@ -6,29 +6,29 @@
 
 use matching::{common_style_affecting_attributes, CommonStyleAffectingAttributeMode};
 use selectors::Element;
 use selectors::parser::{AttrSelector, SelectorImpl};
 
 pub type AttrValue = <TheSelectorImpl as SelectorImpl>::AttrValue;
 
 #[cfg(feature = "servo")]
-pub use servo::selector_impl::*;
+pub use servo::selector_parser::*;
 
 #[cfg(feature = "gecko")]
-pub use gecko::selector_impl::*;
+pub use gecko::selector_parser::*;
 
 #[cfg(feature = "servo")]
-pub use servo::selector_impl::ServoSelectorImpl as TheSelectorImpl;
+pub use servo::selector_parser::ServoSelectorImpl as TheSelectorImpl;
 
 #[cfg(feature = "gecko")]
-pub use gecko::selector_impl::GeckoSelectorImpl as TheSelectorImpl;
+pub use gecko::selector_parser::GeckoSelectorImpl as TheSelectorImpl;
 
 #[cfg(feature = "servo")]
-pub use servo::selector_impl::ServoElementSnapshot as Snapshot;
+pub use servo::selector_parser::ServoElementSnapshot as Snapshot;
 
 #[cfg(feature = "gecko")]
 pub use gecko::snapshot::GeckoElementSnapshot as Snapshot;
 
 #[cfg(feature = "servo")]
 pub use servo::restyle_damage::ServoRestyleDamage as RestyleDamage;
 
 #[cfg(feature = "gecko")]
--- a/servo/components/style/servo/mod.rs
+++ b/servo/components/style/servo/mod.rs
@@ -1,6 +1,6 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 pub mod restyle_damage;
-pub mod selector_impl;
+pub mod selector_parser;
rename from servo/components/style/servo/selector_impl.rs
rename to servo/components/style/servo/selector_parser.rs
--- a/servo/components/style/servo/selector_impl.rs
+++ b/servo/components/style/servo/selector_parser.rs
@@ -2,18 +2,18 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 use {Atom, Prefix, Namespace, LocalName};
 use attr::{AttrIdentifier, AttrValue};
 use cssparser::ToCss;
 use element_state::ElementState;
 use restyle_hints::ElementSnapshot;
-use selector_impl::{ElementExt, PseudoElementCascadeType, TheSelectorImpl};
-use selector_impl::{attr_equals_selector_is_shareable, attr_exists_selector_is_shareable};
+use selector_parser::{ElementExt, PseudoElementCascadeType, TheSelectorImpl};
+use selector_parser::{attr_equals_selector_is_shareable, attr_exists_selector_is_shareable};
 use selectors::{Element, MatchAttrGeneric};
 use selectors::parser::{AttrSelector, ParserContext, SelectorImpl};
 use std::fmt;
 
 /// NB: If you add to this list, be sure to update `each_pseudo_element` too.
 #[derive(Clone, Debug, PartialEq, Eq, Hash)]
 #[cfg_attr(feature = "servo", derive(HeapSizeOf))]
 pub enum PseudoElement {
--- a/servo/components/style/stylesheets.rs
+++ b/servo/components/style/stylesheets.rs
@@ -11,17 +11,17 @@ use cssparser::ToCss as ParserToCss;
 use encoding::EncodingRef;
 use error_reporting::ParseErrorReporter;
 use font_face::{FontFaceRule, parse_font_face_block};
 use keyframes::{Keyframe, parse_keyframe_list};
 use media_queries::{Device, MediaList, parse_media_query_list};
 use parking_lot::RwLock;
 use parser::{ParserContext, ParserContextExtraData, log_css_error};
 use properties::{PropertyDeclarationBlock, parse_property_declaration_list};
-use selector_impl::TheSelectorImpl;
+use selector_parser::TheSelectorImpl;
 use selectors::parser::{Selector, parse_selector_list};
 use servo_url::ServoUrl;
 use std::cell::Cell;
 use std::fmt;
 use std::sync::Arc;
 use style_traits::ToCss;
 use viewport::ViewportRule;
 
rename from servo/components/style/selector_matching.rs
rename to servo/components/style/stylist.rs
--- a/servo/components/style/selector_matching.rs
+++ b/servo/components/style/stylist.rs
@@ -11,17 +11,17 @@ use error_reporting::StdoutErrorReporter
 use keyframes::KeyframesAnimation;
 use media_queries::{Device, MediaType};
 use parking_lot::RwLock;
 use properties::{self, CascadeFlags, ComputedValues, INHERIT_ALL, Importance};
 use properties::{PropertyDeclaration, PropertyDeclarationBlock};
 use quickersort::sort_by;
 use restyle_hints::{RestyleHint, DependencySet};
 use rule_tree::{RuleTree, StrongRuleNode, StyleSource};
-use selector_impl::{ElementExt, TheSelectorImpl, PseudoElement, Snapshot};
+use selector_parser::{ElementExt, TheSelectorImpl, PseudoElement, Snapshot};
 use selectors::Element;
 use selectors::bloom::BloomFilter;
 use selectors::matching::{AFFECTED_BY_STYLE_ATTRIBUTE, AFFECTED_BY_PRESENTATIONAL_HINTS};
 use selectors::matching::{MatchingReason, StyleRelations, matches_complex_selector};
 use selectors::parser::{Selector, SimpleSelector, LocalName as LocalNameSelector, ComplexSelector};
 use sink::Push;
 use smallvec::VecLike;
 use std::borrow::Borrow;
--- a/servo/docs/components/style.md
+++ b/servo/docs/components/style.md
@@ -133,26 +133,26 @@ pseudo-elements**.
 
 Feel free to ping @SimonSapin, @mbrubeck or @emilio on irc, and please mention
 that you didn't find it here so it can be added :)
 
 [style-doc]: http://doc.servo.org/style/index.html
 [wiki-styling-overview]: https://github.com/servo/servo/wiki/Styling-overview
 [stylo]: https://public.etherpad-mozilla.org/p/stylo
 [selector-impl]: http://doc.servo.org/selectors/parser/trait.SelectorImpl.html
-[selector-impl-ext]: http://doc.servo.org/style/selector_impl/trait.SelectorImplExt.html
-[servo-selector-impl]: http://doc.servo.org/style/servo_selector_impl/struct.ServoSelectorImpl.html
+[selector-impl-ext]: http://doc.servo.org/style/selector_parser/trait.SelectorImplExt.html
+[servo-selector-impl]: http://doc.servo.org/style/servo_selector_parser/struct.ServoSelectorImpl.html
 [tree-structural-pseudo-classes]: https://www.w3.org/TR/selectors4/#structural-pseudos
 [style-dom-traits]: http://doc.servo.org/style/dom/index.html
 [layout-wrapper]: http://doc.servo.org/layout/wrapper/index.html
-[pseudo-cascade-type]: http://doc.servo.org/style/selector_impl/enum.PseudoElementCascadeType.html
-[servo-pseudo-elements]: http://doc.servo.org/style/selector_impl/enum.PseudoElement.html
+[pseudo-cascade-type]: http://doc.servo.org/style/selector_parser/enum.PseudoElementCascadeType.html
+[servo-pseudo-elements]: http://doc.servo.org/style/selector_parser/enum.PseudoElement.html
 [mdn-pseudo-before]: https://developer.mozilla.org/en/docs/Web/CSS/::before
 [mdn-pseudo-after]: https://developer.mozilla.org/en/docs/Web/CSS/::after
 [mdn-pseudo-selection]: https://developer.mozilla.org/en/docs/Web/CSS/::selection
-[stylist]: http://doc.servo.org/style/selector_matching/struct.Stylist.html
+[stylist]: http://doc.servo.org/style/stylist/struct.Stylist.html
 [selectors-selectormap]: http://doc.servo.org/selectors/matching/struct.SelectorMap.html
 [selectors-rule]: http://doc.servo.org/selectors/matching/struct.Rule.html
-[per-pseudo-selectormap]: http://doc.servo.org/style/selector_matching/struct.PerPseudoElementSelectorMap.html
-[per-origin-selectormap]: http://doc.servo.org/style/selector_matching/struct.PerOriginSelectorMap.html
+[per-pseudo-selectormap]: http://doc.servo.org/style/stylist/struct.PerPseudoElementSelectorMap.html
+[per-origin-selectormap]: http://doc.servo.org/style/stylist/struct.PerOriginSelectorMap.html
 [docs-pipeline]: https://github.com/servo/servo/blob/master/docs/glossary.md#pipeline
 [properties-module]: http://doc.servo.org/style/properties/index.html
 [properties-cascade-fn]: http://doc.servo.org/style/properties/fn.cascade.html
--- a/servo/ports/geckolib/glue.rs
+++ b/servo/ports/geckolib/glue.rs
@@ -11,17 +11,17 @@ use servo_url::ServoUrl;
 use std::fmt::Write;
 use std::mem::transmute;
 use std::sync::{Arc, Mutex};
 use style::arc_ptr_eq;
 use style::context::{LocalStyleContextCreationInfo, ReflowGoal, SharedStyleContext};
 use style::dom::{NodeInfo, StylingMode, TElement, TNode};
 use style::error_reporting::StdoutErrorReporter;
 use style::gecko::data::{NUM_THREADS, PerDocumentStyleData};
-use style::gecko::selector_impl::{GeckoSelectorImpl, PseudoElement};
+use style::gecko::selector_parser::{GeckoSelectorImpl, PseudoElement};
 use style::gecko::snapshot::GeckoElementSnapshot;
 use style::gecko::traversal::RecalcStyleOnly;
 use style::gecko::wrapper::{GeckoElement, GeckoNode};
 use style::gecko::wrapper::DUMMY_BASE_URL;
 use style::gecko_bindings::bindings::{RawGeckoElementBorrowed, RawGeckoNodeBorrowed};
 use style::gecko_bindings::bindings::{RawServoDeclarationBlockBorrowed, RawServoDeclarationBlockStrong};
 use style::gecko_bindings::bindings::{RawServoStyleSetBorrowed, RawServoStyleSetOwned};
 use style::gecko_bindings::bindings::{RawServoStyleSheetBorrowed, ServoComputedValuesBorrowed};
@@ -37,17 +37,17 @@ use style::gecko_bindings::structs::nsSt
 use style::gecko_bindings::sugar::ownership::{FFIArcHelpers, HasArcFFI, HasBoxFFI};
 use style::gecko_bindings::sugar::ownership::{HasSimpleFFI, Strong};
 use style::gecko_bindings::sugar::refptr::{GeckoArcPrincipal, GeckoArcURI};
 use style::parallel;
 use style::parser::{ParserContext, ParserContextExtraData};
 use style::properties::{CascadeFlags, ComputedValues, Importance, PropertyDeclaration};
 use style::properties::{PropertyDeclarationParseResult, PropertyDeclarationBlock};
 use style::properties::{apply_declarations, parse_one_declaration};
-use style::selector_impl::PseudoElementCascadeType;
+use style::selector_parser::PseudoElementCascadeType;
 use style::sequential;
 use style::string_cache::Atom;
 use style::stylesheets::{Origin, Stylesheet};
 use style::timer::Timer;
 use style_traits::ToCss;
 
 /*
  * For Gecko->Servo function calls, we need to redeclare the same signature that was declared in
--- a/servo/tests/unit/style/lib.rs
+++ b/servo/tests/unit/style/lib.rs
@@ -23,19 +23,19 @@ extern crate util;
 mod atomic_refcell;
 mod attr;
 mod cache;
 mod logical_geometry;
 mod media_queries;
 mod owning_handle;
 mod parsing;
 mod properties;
-mod selector_matching;
 mod str;
 mod stylesheets;
+mod stylist;
 mod value;
 mod viewport;
 
 mod writing_modes {
     use style::logical_geometry::WritingMode;
     use style::properties::{INITIAL_SERVO_VALUES, get_writing_mode};
 
     #[test]
--- a/servo/tests/unit/style/parsing/selectors.rs
+++ b/servo/tests/unit/style/parsing/selectors.rs
@@ -1,15 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 use cssparser::{Parser, ToCss};
 use selectors::parser::{Selector, ParserContext, parse_selector_list};
-use style::selector_impl::TheSelectorImpl;
+use style::selector_parser::TheSelectorImpl;
 
 fn parse(input: &mut Parser) -> Result<Selector<TheSelectorImpl>, ()> {
     let mut context = ParserContext::new();
     context.in_user_agent_stylesheet = true;
     context.namespace_prefixes.insert("svg".into(), ns!(svg));
     parse_selector_list(&context, input).map(|mut vec| vec.pop().unwrap())
 }
 
rename from servo/tests/unit/style/selector_matching.rs
rename to servo/tests/unit/style/stylist.rs
--- a/servo/tests/unit/style/selector_matching.rs
+++ b/servo/tests/unit/style/stylist.rs
@@ -5,18 +5,18 @@
 use cssparser::Parser;
 use html5ever_atoms::LocalName;
 use parking_lot::RwLock;
 use selectors::parser::{LocalName as LocalNameSelector, ParserContext, parse_selector_list};
 use servo_atoms::Atom;
 use std::sync::Arc;
 use style::properties::{PropertyDeclarationBlock, PropertyDeclaration, DeclaredValue};
 use style::properties::{longhands, Importance};
-use style::selector_matching::{Rule, SelectorMap};
 use style::stylesheets::StyleRule;
+use style::stylist::{Rule, SelectorMap};
 use style::thread_state;
 
 /// Helper method to get some Rules from selector strings.
 /// Each sublist of the result contains the Rules for one StyleRule.
 fn get_mock_rules(css_selectors: &[&str]) -> Vec<Vec<Rule>> {
     css_selectors.iter().enumerate().map(|(i, selectors)| {
         let context = ParserContext::new();
         let selectors =