@neutrium/utilities - v5.0.0
    Preparing search index...

    Interface InfixParselet<T, Node>

    A binary, postfix or other continuation of an already parsed expression.

    interface InfixParselet<T extends SourceSpan, Node> {
        bindingPower: number;
        consumeToken?: boolean;
        parse: (context: PrattContext<T, Node>, left: Node, token: T) => Node;
    }

    Type Parameters

    Index
    bindingPower: number

    Nonnegative safe integer below Number.MAX_SAFE_INTEGER. Higher values bind more tightly.

    consumeToken?: boolean

    Defaults to true. Set false for implicit operators; the handler must then consume input itself.

    parse: (context: PrattContext<T, Node>, left: Node, token: T) => Node

    token is consumed first unless consumeToken is false. Parse additional operands using context.