in reply to Re: regex man they are tough
in thread regex man they are tough

the /g modifier makes sense only if you are matching the same string multiple times
Not entirely true. In scalar context (such as when it's the conditional of a while), it's about repeated matching. In list context, it will do the global match and return all the captures at once.
$_ = 'pig dog goggles'; my @hits = /g/g; print "@hits\n";

Caution: Contents may have been coded under pressure.