gohaku wrote:
Hi everyone,
Sorry for asking this question again for what must be the umpteenth time but I have a problem with
the g modifier when matching. I have read Newsgroup Postings about this topic including:
"What good is \G in a regular expression?"


G is likely best for s/// syntax as there is a
better (?:test) for pattern matching in
general:

$_ = "I match it All, so you dont have to";

s%a%_%ig;

print "$_";

you get
I m_tch it _ll, so you dont h_ve to

G just causes the match to match everywhere
the pattern is to be found. But NOT beyond
the end of the line (\n) which is a logical
record separator...

HTH;
-Sx-

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to