Function selectors::matching::matches_complex_selector [] [src]

pub fn matches_complex_selector<E>(selector: &ComplexSelector<E::Impl>,
                                   element: &E,
                                   parent_bf: Option<&BloomFilter>,
                                   relations: &mut StyleRelations,
                                   reason: MatchingReason)
                                   -> bool where E: Element

Determines whether the given element matches the given complex selector.

NB: If you add support for any new kinds of selectors to this routine, be sure to set shareable to false unless you are willing to update the style sharing logic. Otherwise things will almost certainly break as elements will start mistakenly sharing styles. (See can_share_style_with in servo/components/style/matching.rs.)