in reply to Re: Functions in substitutions (s///) and Perl 5.8.
in thread Functions in substitutions (s///) and Perl 5.8.
while (m/\[\[\w+\]\]/) { my $oldpos = pos; m/\[\[(\w+)\]\]/; my $expansion = $helper->($1); pos = $oldpos; s/\[\[$1\]\]/$expansion/; }
|
|---|