sub register { my ($eref, $fref) = @_; my %error = %$eref; my %FORM = %$fref; # ... } # # Call it like so: # register(\%error, \%FORM);