foo(\%hash); sub foo { my %hash = %{shift()}; # rest of function here, which manipulates hash directly }