For a given array of GeneralParsers, if any of them is a
CaptureParser, PickParserType says the array is an array of
CaptureParsers, otherwise it's an array of Parsers. It also
correctly merges the result and capture types. This is useful for a
combinator like or which is not able to infer its
return type correctly.
For a given array of GeneralParsers, if any of them is a CaptureParser, PickParserType says the array is an array of CaptureParsers, otherwise it's an array of Parsers. It also correctly merges the result and capture types. This is useful for a combinator like
or
which is not able to infer its return type correctly.