Skip to main content

run_query

Function run_query 

Source
pub fn run_query(
    tree: &Tree,
    lang: &Language,
    source: &[u8],
    pattern: &str,
) -> Vec<Vec<QueryMatch>>
Expand description

Outer Vec = each pattern match, inner = captures within that match (in capture-list order). Empty on pattern compile error rather than panic — pattern strings can come from external plugins.