For example, I have the following code:
group((
a.recover_with(via_parser(empty()))
a.or(b).recover_with(via_parser(empty()))
))
I would like to get one error like "expected a or b".
There may be a problem like "but it's expensive to check the entire list of secondary errors", but aren't the errors simply ordered by location based on how it is generated?
On the other hand, some of the parsers erase some of the secondary errors that have formed, which can be a problem, but you can still merge at least those errors that have formed in the "common area". That is, those that arose as a result of a single child parser inside such erasing parsers.