in reply to Hash-slicing question...
You can change this to true defaults if you switch the order to:sub functionCall{ my ($hashref) = @_; my %defaults = ( A => 1, D => 4, ); %$hashref = ( %$hashref, %defaults, ); }
%$hashref = ( %defaults, %$hashref, );
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Hash-slicing question...
by dragonchild (Archbishop) on Aug 29, 2001 at 16:21 UTC |