generic "pattern" hahyaha
$var =~ s{(yada)}{OtherSubstitute("$1")}ge; sub OtherSubstitute { my( $in ) = @_; ## $in =~ s{yada}{yada}g; my $numlines = $in =~ tr/\n/\n/; ## count return "\n" x $numlines; }
In reply to Re: nested replace
by Anonymous Monk
in thread nested replace
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |