in reply to are TypeGlob assingments to a lexical variables possible?
There's not a native Perl way to do that, but there is japhy's Lexical::Alias. Watch this!
use strict; use warnings; use Lexical::Alias; my $src = { one => 1, two => 2 }; my %dest; alias %{$src}, %dest; print keys %dest, "\n"; $dest{three} = 3; print $src->{three}, "\n";
Dave
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: are TypeGlob assingments to a lexical variables possible?
by cems22 (Initiate) on Sep 25, 2006 at 13:55 UTC |