in reply to Is there an easy way to parse and modify regular expressions programmatically

I haven't worked with it myself, but maybe PPIx::Regexp is worth looking into. I suspect that similar to PPI, it probably doesn't support the full range of Perl features.

However it sounds like you might want to be using named capture groups with unique names rather than plain numbered capture groups?

  • Comment on Re: Is there an easy way to parse and modify regular expressions programmatically