mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Run rustfmt on selectors, servo_arc, and style.
This was generated with: ./mach cargo fmt --package selectors && ./mach cargo fmt --package servo_arc && ./mach cargo fmt --package style Using rustfmt 0.4.1-nightly (a4462d1 2018-03-26)
This commit is contained in:
parent
f7ae1a37e3
commit
c99bcdd4b8
181 changed files with 9981 additions and 7933 deletions
|
@ -17,7 +17,10 @@ use std::fmt;
|
|||
use string_cache::Atom;
|
||||
use values::serialize_atom_identifier;
|
||||
|
||||
include!(concat!(env!("OUT_DIR"), "/gecko/pseudo_element_definition.rs"));
|
||||
include!(concat!(
|
||||
env!("OUT_DIR"),
|
||||
"/gecko/pseudo_element_definition.rs"
|
||||
));
|
||||
|
||||
impl ::selectors::parser::PseudoElement for PseudoElement {
|
||||
type Impl = SelectorImpl;
|
||||
|
@ -42,11 +45,11 @@ impl PseudoElement {
|
|||
pub fn cascade_type(&self) -> PseudoElementCascadeType {
|
||||
if self.is_eager() {
|
||||
debug_assert!(!self.is_anon_box());
|
||||
return PseudoElementCascadeType::Eager
|
||||
return PseudoElementCascadeType::Eager;
|
||||
}
|
||||
|
||||
if self.is_precomputed() {
|
||||
return PseudoElementCascadeType::Precomputed
|
||||
return PseudoElementCascadeType::Precomputed;
|
||||
}
|
||||
|
||||
PseudoElementCascadeType::Lazy
|
||||
|
@ -73,7 +76,9 @@ impl PseudoElement {
|
|||
/// Gets the canonical index of this eagerly-cascaded pseudo-element.
|
||||
#[inline]
|
||||
pub fn eager_index(&self) -> usize {
|
||||
EAGER_PSEUDOS.iter().position(|p| p == self)
|
||||
EAGER_PSEUDOS
|
||||
.iter()
|
||||
.position(|p| p == self)
|
||||
.expect("Not an eager pseudo")
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue