import { Node } from 'web-tree-sitter';
export interface MatchResult {
    isMatch: boolean;
    bindings: Record<string, Node>;
}
export declare class Matcher {
    /**
     * Matches a pattern node against a source node.
     * Returns an array of MatchResults with bindings if successful.
     */
    match(patternNode: Node, sourceNode: Node): MatchResult[];
    private isMetavariable;
    private matchChildren;
    private matchRecursive;
    /**
     * Merges two binding sets, ensuring consistency.
     * Returns null if there is a conflict.
     */
    mergeBindings(b1: Record<string, Node>, b2: Record<string, Node>): Record<string, Node> | null;
    /**
     * Checks if a metavariable in the bindings matches a regex.
     */
    checkMetavariableRegex(metavariable: string, regex: string, bindings: Record<string, Node>): boolean;
    private isEllipsis;
    private isStringWildcard;
}
