in reply to Lexical::Alias & subroutines

Just curious, but why is the following so ugly that you would resort to making some kind of alias?
sub foo { my $byRef = shift; ... }

--
[ e d @ h a l l e y . c c ]

Replies are listed 'Best First'.
Re: Re: Lexical::Alias & subroutines
by pfaut (Priest) on May 19, 2003 at 13:01 UTC

    Shifting makes $byRef a copy of the variable passed to the sub. Jenda indicated he wants to modify the argument passed to the sub so he needs an alias. $_[0] is an alias but he'd like to work with it using a more friendly name.

    90% of every Perl application is already written.
    dragonchild