in reply to Splitting a string while respecting parentheses

You may try to
use Text::Balanced; # and
use Regexp::Common qw/balanced/;
  • Comment on Re: Splitting a string while respecting parentheses