in reply to Re: Referencing a HoH
in thread Referencing a HoH

What do I do here? Is something like this possible?
foreach $key (keys %hshFoo) { %hsh2 = bless($hshFoo{$key}); foreach $key2 (keys %hsh2) { # ...do something w/ %hsh2 here } }
It appears that %hsh2 becomes unusable if I try to put it in place of %hshFoo in the loop above. When I evaluate %hsh2 in the debugger I see FOO:HASH(0x1ddba60) versus $hshFoo=HASH(0x1ddba60). Is this a proper use of bless() in this instance?

-P0w3rK!d

Replies are listed 'Best First'.
Re: Re: Re: Referencing a HoH
by Mr. Muskrat (Canon) on May 07, 2003 at 17:57 UTC
    No need to bless it... my %hsh2 = %{$hshFoo{$key}};