Closed groupsvkg closed 3 years ago
I hope 7a7a180 solves this? With the optional arguments failureMessage
and failurePosition
you can customize the generated error: https://github.com/petitparser/dart-petitparser/blob/main/petitparser/lib/src/parser/action/where.dart
Hello,
Can you please share an example of - how to throw custom Failure message in parser.
I can see Failure message when "word" is not an instance of the grammar. For the case when "word" is instance of the grammar. How can I throw custom Failure message when I know constraint failed in parser.
Regards, Vishal