in reply to Re: •Re: positions of all regexp matches
in thread positions of all regexp matches
Oddly enough, that would find no matches if $regex began with \n. Sloppy coding. No need for that "." in there anyway.() = $string =~ /(?=$regex)(?{push @matches, pos})./g;
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re:^4 positions of all regexp matches
by flounder99 (Friar) on Oct 14, 2003 at 19:57 UTC | |
by merlyn (Sage) on Oct 14, 2003 at 20:04 UTC | |
by sandfly (Beadle) on Oct 14, 2003 at 22:40 UTC |