amazotron has asked for the wisdom of the Perl Monks concerning the following question:
Why must I qualify uses of aa as in Foo::aa? If I don't I get the error "Variable @aa not imported at xxx line yyy". By the way, having to qualify all the uses of aa is what I'm trying to avoid.package Foo; use strict; sub Test { my @a = (1,2,3); my $aref = \@a; local (*aa) = $aref; push (@aa, 4); # line 11 print "aa:",join(",",@aa),"\n"; # line 12 } Test ();
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: symbol tables and class data members
by stephen (Priest) on May 06, 2002 at 18:32 UTC | |
by amazotron (Novice) on May 06, 2002 at 18:39 UTC |