http://www.perlmonks.org?node_id=1004289


in reply to Capturing all instances of a repeating sub-pattern in regex

This question strikes me as an example of just because TMTOWDI doesn't mean you should choose the most complex.

Choosing a less ambitious way of doing it will result in more maintainable Perl and I doubt it will harm your program in terms of performance too much.

A Monk aims to give answers to those who have none, and to learn from those who know more.