in reply to Need cleaner way to read @_ when dereferencing
sub myfunc($\@\@$) { my $var1 = $_[0]; my @arr1 = @{$_[1]}; my @arr2 = @{$_[2]}; my $var2 = $_[3]; }
Secondly, your second version is what should happen, except you don't have to dereference $tmp1 and $tmp2. You can replace as so:
@arr1[3] --- $tmp1->[3]
Hope that helps!
------
We are the carpenters and bricklayers of the Information Age.
Please remember that I'm crufty and crochety. All opinions are purely mine and all code is untested, unless otherwise specified.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Need cleaner way to read @_ when dereferencing
by Roy Johnson (Monsignor) on Jan 14, 2004 at 17:29 UTC | |
by dragonchild (Archbishop) on Jan 14, 2004 at 17:44 UTC | |
by welchavw (Pilgrim) on Jan 15, 2004 at 03:28 UTC |