On Fri, Feb 25, 2022, 13:19 <em...@greglondon.com> wrote: > Is there a way to get better built in reporting with regexps? > with the above, if the string doesn't match, I get "bad input". > > What I'd rather get is something like "expecting \:thing2" >
That behavior is more associated with full on parser modules built with grammars . For bespoke Perl *sans* modules, you'll need to structure your match/diagnose code as a parser and not simple matxh-extract. Did MJD HOP book cover this? Or Manning Data Munging? > _______________________________________________ Boston-pm mailing list Boston-pm@pm.org https://mail.pm.org/mailman/listinfo/boston-pm