in reply to Re: Dereferencing nested references
in thread Dereferencing nested references
push @BuySellHashref, { %{$hash_ref} };
This is what I'm having trouble wrapping myself around. I'm not sure I understand exactly what's happening in this snip, so I'll try to break it down the way I see it, and if I'm way out in left field, I'll get some feedback.
%{$hash_ref}
This dereferences $hash_ref and then...
push @BuySellHashref, { dereferenced $hash_ref }
This creates an anonymous hash containing the hash data from the dereferenced $hash_ref and pushes a reference to it into @BuySellHashref, which means instead of just having the original ref (or as in my original code a ref to a ref), I have a ref to an anonymous hash containing all the original data from $hash_ref.
ryddler
|
|---|