in reply to
Re: Re: style q: duplication? of variables
in thread style q: duplication? of variables
I definitely don't like it when in a language I can't see at the function call whether an argument might be changed.
Well, you picked a trivial example (scalars, specifically strings). In much of the Perl code you'll see, references are being passed around anyway, since plain old scalars have limited usefulness.
What you may want to do is to adopt a naming convention to signify subroutines that take scalar arguments and modify them.
You note that this was a disadvantage of Ruby; but note that Ruby has a convention of using a trailing '!' sign to denote methods that modify value types (especially) in place (i.e. chomp!() vs. chomp()). Maybe your Perl code could do something similar (i.e. truncate() vs. truncated(), perhaps).