in reply to Re^4: Counting matches and removing duplicates
in thread Counting matches and removing duplicates

Yes, but you will need the same loop. ie.

my @matches; push @matches, $1 while $xml =~ /$regex/g;

🦛