in reply to (jcwren) RE: modify variable on pass by value
in thread modify variable on pass by value
That said I will admit to occasionally using the following hack that assumes that if you want a scalar back, you will always give me exactly one value. (I know, still I do it from time to time.)
sub remove_caps; if (1 != @_) { return map {remove_caps($_)} @_; } my $str = shift; $str =~ tr/A-Z//d; return $str; }
|
|---|