in reply to Re: Replacing string with regexp without using modules
in thread Replacing string with regexp without using modules
Could it be the hash reference you use to the subroutine? \$hash ? Thanks.$string = '$a $b $c'; $hash{a} = "go"; $string =~ s{\$(\w+)}{$$hash{$1}}ge;
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Replacing string with regexp without using modules
by almut (Canon) on Aug 06, 2008 at 01:58 UTC |