Skip to main content

Module matching

Module matching 

Source

Re-exportsΒ§

pub use crate::context::*;

StructsΒ§

ElementSelectorFlags
Set of flags that are set on either the element or its parent (depending on the flag) if the element could potentially match a selector.
LocalMatchingContext πŸ”’
Holds per-compound-selector data.
NextElement πŸ”’

EnumsΒ§

CompoundSelectorMatchingResult
Whether a compound selector matched, and whether it was the rightmost selector inside the complex selector.
SelectorMatchingResult πŸ”’
A result of selector matching, includes 3 failure types,
SubjectOrPseudoElement
Whether we’re matching either the subject, or the pseudo-element.

StaticsΒ§

RECOMMENDED_SELECTOR_BLOOM_FILTER_SIZE

FunctionsΒ§

assigned_slot πŸ”’
complex_selector_early_reject_by_local_name πŸ”’
compound_matches_featureless_host πŸ”’
There are relatively few selectors in a given compound that may match a featureless element. Instead of adding a check to every selector that may not match, we handle it here in an out of line path.
do_match_relative_selectors πŸ”’
Matches a relative selector in a list of relative selectors.
early_reject_by_local_name
Returns true if this compound would not match the given element by due to a local name selector (If one exists).
host_for_part πŸ”’
hover_and_active_quirk_applies πŸ”’
Whether the :hover and :active quirk applies.
match_relative_selectors πŸ”’
matches_complex_selector
Matches a complex selector.
matches_complex_selector_internal πŸ”’
matches_complex_selector_list πŸ”’
Matches each selector of a list as a complex selector
matches_compound_selector πŸ”’
Determines whether the given element matches the given compound selector.
matches_compound_selector_from
Matches a compound selector belonging to selector, starting at offset from_offset, matching left to right.
matches_generic_nth_child πŸ”’
matches_host πŸ”’
matches_local_name πŸ”’
matches_part πŸ”’
matches_rare_attribute_selector πŸ”’
matches_relative_selector πŸ”’
matches_relative_selector_subtree πŸ”’
matches_selector
Matches a selector, fast-rejecting against a bloom filter.
matches_selector_kleene
Same as matches_selector, but returns the Kleene value as-is.
matches_selector_list
matches_simple_selector πŸ”’
Determines whether the given element matches the given single selector.
matches_slotted πŸ”’
next_element_for_combinator πŸ”’
nth_child_index πŸ”’
relative_selector_match_early πŸ”’
select_name
selector_may_match
Given the ancestor hashes from a selector, see if the current element, represented by the bloom filter, has a chance of matching at all.
to_unconditional_case_sensitivity