- recursive<TToken, TOptions, TValue>(f: (() => Matcher<TToken, TOptions, TValue>)): Matcher<TToken, TOptions, TValue>
-
Parameters
-
f: (() => Matcher<TToken, TOptions, TValue>)
-
- (): Matcher<TToken, TOptions, TValue>
-
Returns Matcher<TToken, TOptions, TValue>
Returns Matcher<TToken, TOptions, TValue>
- recursive<TToken, TOptions, TValue>(f: (() => Parser<TToken, TOptions, TValue>)): Parser<TToken, TOptions, TValue>
-
Parameters
-
f: (() => Parser<TToken, TOptions, TValue>)
-
- (): Parser<TToken, TOptions, TValue>
-
Returns Parser<TToken, TOptions, TValue>
Returns Parser<TToken, TOptions, TValue>
A wrapper that helps to create recursive parsers - allows to refer to a parser defined later in the code.
Alternatively, parsers defined/wrapped as functions (rather than constants obtained by composition) don't need this.
This overload is for Matchers.
Returns
A parser wrapped into a function.