http://qs321.pair.com?node_id=768141


in reply to Re: regular expression help
in thread regular expression help

...consider splitting...
Or define your X subpattern as a separate regex, then build the pattern with it:
my $subpat = qr/(?:<\*\d+>)?([^<]+)<(\d+):(\d+)>/; $str =~/$subpat(?:,$subpat)*/;
However, the capturing parentheses are not going to capture everything this way.

Caution: Contents may have been coded under pressure.