I think in this case you need to return a reference to a glob and dereference it with *
DB<101> $a=42 => 42 DB<102> sub ret_gr { \*a } DB<103> $b=666 => 666 DB<105> *{ret_gr()}=*b DB<106> $a # *a is now an alias of *b => 666 DB<107> $b => 666 DB<108> $a=0 => 0 DB<109> $b => 0
Cheers Rolf
(addicted to the Perl Programming Language and ☆☆☆☆ :)
In reply to Re: Returning and using a glob from a sub.
by LanX
in thread Returning and using a glob from a sub.
by mephtu
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |