Creates a Parser that matches only if the first Parser matches input at the starting position, but the second Parser does not.
Signature:
export declare function except<T, U>(match: Parser<T>, except: Parser<U>, expected: string[]): Parser<T>;
Parameter | Type | Description |
---|---|---|
match | Parser<T> | Parser that should match |
except | Parser<U> | Parser that should not match |
expected | string[] | Expected values for parse errors generated when the except parser succeeds |
Returns:
Parser<T>