- or download this
my $new_string = testing_string($string);
...
$content =~ s/a/b/sg;
return $content; #string copy, expensive
}
- or download this
# do stuff here
my %test_var;
...
# do some stuff here
$test_var{$string} =~ s/a/b/sg;
}
- or download this
testing_string(\$string); #send a reference to $string instead of $
+string
...
# do some stuff
$$contentref =~ s/a/b/sg;
}