in reply to how do I use a hash of hashes reference to a function ?
foo(\%hash); sub foo { my %hash = %{shift()}; # rest of function here, which manipulates hash directly }
Call me perverse, but I just love the way that line looks (from what I understant, the () is required when you put shift in the braces to force perl to recognize it as a function call and not a hash key ... but I've been wrong about these things in the past ...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
RE: Answer: how do I use a hash of hashes reference to a function ?
by Fastolfe (Vicar) on Sep 22, 2000 at 19:55 UTC |