Skip to main content

orderless_match

Function orderless_match 

Source
pub fn orderless_match(
    query: &str,
    target: &str,
) -> Option<(MatchScore, Vec<Range<usize>>)>
Expand description

Match target against an orderless query.

Returns None when any positive component fails to match or any negated component matches. Returned byte ranges are into target, sorted and merged, so a renderer can highlight every component’s hit without handling overlaps.

See the module docs for syntax and scoring.