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


in reply to How does one get all possible matches from regex?

Your "correct results" don't correspond to what I get; if you want "all possible matches for REGEX," you should use this:
1 while /REGEX(?{print $&})(?!)/;
i.e. "match REGEX, print what it matched, then fail."